Skip to content

Commit 4649d94

Browse files
committed
test: fix expectation
1 parent 21b16c9 commit 4649d94

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

features/open_api.feature

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ Feature: Generate Open API Specification from test examples
290290
And the exit status should be 0
291291

292292
Scenario: Index file should look like we expect
293-
Then the file "doc/api/open_api.json" should contain exactly:
293+
Then the file "doc/api/open_api.json" should contain JSON exactly like:
294294
"""
295295
{
296296
"swagger": "2.0",
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
Then /^the file "(.*?)" should contain JSON exactly like:$/ do |file, exact_content|
2-
expect(JSON.parse(read(file).join)).to eq(JSON.parse(exact_content))
2+
actual = JSON.dump(JSON.parse(read(file).join))
3+
expected = JSON.dump(JSON.parse(exact_content))
4+
expect(actual).to eq(expected)
35
end

0 commit comments

Comments
 (0)