Skip to content

Commit

Permalink
Fix --test-probe
Browse files Browse the repository at this point in the history
1. Changes `folder` to `dir.to_s` (`folder` no longer exists).
2. Changes `passing.any?` to `!passing.empty?`, as `any?` has pitfalls:
   Took me a few minutes to debug when I tried with `input_path` that
   was returning `nil` (`[nil].any? #=> false`).
  • Loading branch information
glebm committed Mar 25, 2019
1 parent 150cdc5 commit e030713
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/sass_spec/runner.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,10 @@ def run
passing = []
test_cases.each do |test_case|
if test_case.todo? && test_case.result?
passing << test_case.folder
passing << test_case.dir.to_s
end
end
if passing.any?
if !passing.empty?
puts "The following tests pass but were marked as TODO for #{@options[:engine_adapter].describe}:"
puts passing.join("\n")
else
Expand Down

0 comments on commit e030713

Please sign in to comment.