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

Unified Diff: tools/json_schema_compiler/idl_schema_test.py

Issue 10080014: Fix a bug in IDL parsing related to arrays of callbacks. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: added in test file Created 8 years, 8 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_callback_arrays.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 59fcd6da00710da317b60d1bf3296bae4166b169..d045f6206513a16cd44ff13395ff8da51d07ddae 100755
--- a/tools/json_schema_compiler/idl_schema_test.py
+++ b/tools/json_schema_compiler/idl_schema_test.py
@@ -43,5 +43,13 @@ class IdlSchemaTest(unittest.TestCase):
'items':{'$ref':'MyType2'}}]}]
self.assertEquals(expected, getParams(schema, 'function12'))
+
+ def testArrayOfCallbacks(self):
+ schema = idl_schema.Load('test/idl_callback_arrays.idl')[0]
+ expected = [{'type':'array', 'name':'callbacks',
+ 'items':{'type':'function', 'name':'MyCallback',
+ 'parameters':[{'type':'integer', 'name':'x'}]}}]
+ self.assertEquals(expected, getParams(schema, 'whatever'))
+
if __name__ == '__main__':
unittest.main()
« no previous file with comments | « tools/json_schema_compiler/idl_schema.py ('k') | tools/json_schema_compiler/test/idl_callback_arrays.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698