Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(12)

Unified Diff: tools/json_schema_compiler/idl_schema_test.py

Issue 11826020: IDL schema compiler: Fixed pseudo-random order (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Incorporate upstream changes. Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/json_schema_compiler/idl_schema.py ('k') | tools/json_schema_compiler/test/idl_basics.idl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/json_schema_compiler/idl_schema_test.py
diff --git a/tools/json_schema_compiler/idl_schema_test.py b/tools/json_schema_compiler/idl_schema_test.py
index 873333b03a5b18724704810f76b230b0591c8a70..26a382ad64abf752d925786c5e225612c6b88fa1 100755
--- a/tools/json_schema_compiler/idl_schema_test.py
+++ b/tools/json_schema_compiler/idl_schema_test.py
@@ -60,9 +60,18 @@ class IdlSchemaTest(unittest.TestCase):
self.assertEquals({
'x': {'name': 'x', 'type': 'integer', 'enum': [1,2],
'description': 'This comment tests "double-quotes".'},
- 'y': {'name': 'y', 'type': 'string'}},
+ 'y': {'name': 'y', 'type': 'string'},
+ 'z': {'name': 'z', 'type': 'string'},
+ 'a': {'name': 'a', 'type': 'string'},
+ 'b': {'name': 'b', 'type': 'string'},
+ 'c': {'name': 'c', 'type': 'string'}},
getType(self.idl_basics, 'MyType1')['properties'])
+ def testMemberOrdering(self):
+ self.assertEquals(
+ ['x', 'y', 'z', 'a', 'b', 'c'],
+ getType(self.idl_basics, 'MyType1')['properties'].keys())
+
def testEnum(self):
schema = self.idl_basics
expected = {'enum': ['name1', 'name2'], 'description': 'Enum description',
« no previous file with comments | « tools/json_schema_compiler/idl_schema.py ('k') | tools/json_schema_compiler/test/idl_basics.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698