Skip to content

Commit

Permalink
Fix cucumber_opts warning
Browse files Browse the repository at this point in the history
I was reading the [Developing Reek Contributing](https://github.com/JuanVqz/reek?tab=readme-ov-file#developing-reek--contributing)
to understand how `reek` works, then run the `rake console` and saw
the `warning` message.

```ruby
➜  reek git:(master) be rake console
WARNING: consider using an array rather than a space-delimited string with cucumber_opts to avoid undesired behavior.

BEFORE
➜  reek git:(master) rg cucumber_opts .
./tasks/test.rake
21:    t.cucumber_opts = 'features --format progress --color'

AFTER
➜  reek git:(master) rg cucumber_opts .
./tasks/test.rake
21:    t.cucumber_opts = ['features --format', 'progress --color']
```
  • Loading branch information
JuanVqz committed Oct 9, 2023
1 parent ab129ff commit d4b480c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tasks/test.rake
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ namespace 'test' do
end

Cucumber::Rake::Task.new(:features) do |t|
t.cucumber_opts = 'features --format progress --color'
t.cucumber_opts = ['features --format', 'progress --color']
end

desc 'Runs all unit tests and acceptance tests'
Expand Down

0 comments on commit d4b480c

Please sign in to comment.