Skip to content

Commit

Permalink
Ignore missing aggregate_failures support on older versions of RSpec
Browse files Browse the repository at this point in the history
  • Loading branch information
jasoncodes committed Oct 18, 2019
1 parent b767bc9 commit 6cb2758
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion spec/rspec_junit_formatter_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,11 @@ def execute_example_spec
expect(failed_multiple_testcases.size).to eql(1)
failed_multiple_testcases.each do |testcase|
expect(testcase.text).to include("foo")
expect(testcase.text).to include("bar")
if Gem::Version.new(RSpec::Core::Version::STRING) >= Gem::Version.new('3.3')
expect(testcase.text).to include("bar")
else
expect(testcase.text).to_not include("bar")
end
end

# it cleans up diffs
Expand Down

0 comments on commit 6cb2758

Please sign in to comment.