Skip to content

Commit aa52442

Browse files
committed
Fix assertion when rspec-json_expectations is missing
In 21f5743 the output was changed and the code path when rspec-json_expectations is present was updated, but not without. While this is an odd code path (since Gemfile does declare it as a dependency), it can be hit if a different dependency mechanism is used and the expectations should be correct. Fixes: 21f5743
1 parent ff9c9a6 commit aa52442

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

spec/unit/puppet-lint/bin_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -378,7 +378,7 @@ def initialize(args)
378378
if respond_to?(:include_json)
379379
is_expected.to include_json([[{ 'KIND' => 'WARNING' }]])
380380
else
381-
is_expected.to match(%r{\[\n \{})
381+
is_expected.to match(%r{\[\n \[\n \{})
382382
end
383383
end
384384
end
@@ -397,7 +397,7 @@ def initialize(args)
397397
if respond_to?(:include_json)
398398
is_expected.to include_json([[{ 'KIND' => 'ERROR' }], [{ 'KIND' => 'WARNING' }]])
399399
else
400-
is_expected.to match(%r{\[\n \{})
400+
is_expected.to match(%r{\[\n \[\n \{})
401401
end
402402
end
403403
end

0 commit comments

Comments
 (0)