Skip to content

Commit 41298bc

Browse files
committed
Fix echo api
1 parent 4863b63 commit 41298bc

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

samples/client/echo_api/python/tests/test_manual.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
import datetime
1717
import base64
1818
import os
19+
import json
1920

2021
import openapi_client
2122
from openapi_client import StringEnumRef
@@ -218,9 +219,9 @@ def test_from_to_methods(self):
218219
assert pet.category is not None
219220
self.assertEqual(pet.category.id, 1)
220221
# test to_json
221-
self.assertEqual(pet.to_json(),
222-
'{"id": 1, "name": "test name", "category": {"id": 1, "name": "dog"}, "photoUrls": ['
223-
'"string"], "tags": [{"id": 1, "name": "None"}], "status": "available"}')
222+
self.assertEqual(json.loads(pet.to_json()),
223+
{"id": 1, "name": "test name", "category": {"id": 1, "name": "dog"}, "photoUrls": ["string"],
224+
"tags": [{"id": 1, "name": "None"}], "status": "available"})
224225

225226
# test to_dict
226227
self.assertEqual(pet.to_dict(),

0 commit comments

Comments
 (0)