Lines Matching refs:schema
11 def getFunction(schema, name):
12 for item in schema['functions']:
18 def getParams(schema, name):
19 function = getFunction(schema, name)
23 def getReturns(schema, name):
24 function = getFunction(schema, name)
28 def getType(schema, id):
29 for item in schema['types']:
43 schema = self.idl_basics
45 self.assertEquals(expected, getParams(schema, 'function4'))
49 self.assertEquals(expected, getParams(schema, 'function5'))
53 self.assertEquals(expected, getParams(schema, 'function6'))
56 schema = self.idl_basics
60 self.assertEquals(expected, getParams(schema, 'function12'))
64 schema = idl_schema.Load('test/idl_function_types.idl')[0]
68 self.assertEquals(expected, getParams(schema, 'whatever'))
87 schema = self.idl_basics
92 self.assertEquals(expected, getType(schema, expected['id']))
97 self.assertEquals(expected, getParams(schema, 'function13'))
101 self.assertEquals(expected, getParams(schema, 'function14'))
104 schema = self.idl_basics
106 self.assertEquals(expected, getParams(schema, 'function20'))
111 self.assertEquals(expected, getParams(schema, 'function21'))
115 self.assertEquals(expected, getParams(schema, 'function22'))
121 self.assertEquals(expected, getParams(schema, 'function23'))
124 schema = self.idl_basics
125 func = getFunction(schema, 'function15')
130 schema = self.idl_basics
131 enum_with_nodoc = getType(schema, 'EnumTypeWithNoDoc')
142 schema = self.idl_basics
144 getReturns(schema, 'function24'))
147 getReturns(schema, 'function25'))
150 getReturns(schema, 'function26'))
153 getReturns(schema, 'function27'))
156 getReturns(schema, 'function28'))
160 getReturns(schema, 'function29'))
163 getReturns(schema, 'function30'))
166 schema = idl_schema.Load('test/idl_namespace_chromeos.idl')[0]
167 self.assertEquals('idl_namespace_chromeos', schema['namespace'])
169 self.assertEquals(expected, schema['platforms'])
172 schema = idl_schema.Load('test/idl_namespace_all_platforms.idl')[0]
173 self.assertEquals('idl_namespace_all_platforms', schema['namespace'])
175 self.assertEquals(expected, schema['platforms'])
178 schema = idl_schema.Load('test/idl_namespace_non_specific_platforms.idl')[0]
180 schema['namespace'])
182 self.assertEquals(expected, schema['platforms'])
185 schema = idl_schema.Load('test/idl_namespace_specific_implement.idl')[0]
187 schema['namespace'])
189 self.assertEquals(expected, schema['compiler_options']['implemented_in'])
192 schema = idl_schema.Load(
195 schema['namespace'])
199 schema['compiler_options']['implemented_in'])
200 self.assertEquals(expected_platform, schema['platforms'])
203 schema = self.idl_basics
205 getParams(schema, 'function16')[0]['description'])
208 getParams(schema, 'function16')[0]['parameters'][0]['description'])
211 getParams(schema, 'function17')[0]['parameters'][0]['description'])
214 getParams(schema, 'function18')[0]['description'])
217 schema = self.idl_basics
218 func = getFunction(schema, 'function3')
228 func = getFunction(schema, 'function4')
234 schema = idl_schema.Load('test/idl_reserved_words.idl')[0]
236 foo_type = getType(schema, 'Foo')
240 enum_type = getType(schema, 'enum')
244 dictionary = getType(schema, 'dictionary')
247 mytype = getType(schema, 'MyType')
250 params = getParams(schema, 'static')
255 schema = idl_schema.Load('test/idl_object_types.idl')[0]
257 foo_type = getType(schema, 'FooType')
270 bar_type = getType(schema, 'BarType')
275 schema = idl_schema.Load('test/idl_object_types.idl')[0]
277 params = getParams(schema, 'objectFunction1')
282 params = getParams(schema, 'objectFunction2')
286 schema = idl_schema.Load('test/idl_object_types.idl')[0]
288 baz_type = getType(schema, 'BazType')
295 schema = idl_schema.Load('test/idl_object_types.idl')[0]
297 union_type = getType(schema, 'UnionType')
332 schema = idl_schema.Load('test/idl_object_types.idl')[0]
334 union_type = getType(schema, 'ModifiedUnionType')
353 schema = idl_schema.Load('test/idl_function_types.idl')[0]
355 union_params = getParams(schema, 'union_params')
367 schema = idl_schema.Load('test/idl_function_types.idl')[0]
369 blah_params = getParams(schema, 'blah')
381 badabish_params = getParams(schema, 'badabish')