Index: tools/json_schema_compiler/test/enums.json |
diff --git a/tools/json_schema_compiler/test/enums.json b/tools/json_schema_compiler/test/enums.json |
index ae6be004d84a5facc09f945ce79bad0acb5459d0..48c2c980ddf5526168c9be83dd5a948c8b81a2ea 100644 |
--- a/tools/json_schema_compiler/test/enums.json |
+++ b/tools/json_schema_compiler/test/enums.json |
@@ -3,6 +3,10 @@ |
"namespace": "enums", |
"types": [ |
{ |
+ "id": "Enumeration", |
+ "enum": ["none", "one", "two", "three"] |
+ }, |
+ { |
"id": "EnumType", |
"type": "object", |
"properties": { |
@@ -13,6 +17,19 @@ |
} |
}, |
{ |
+ "id": "HasEnumeration", |
+ "type": "object", |
+ "properties": { |
+ "enumeration": { |
+ "$ref": "Enumeration" |
+ }, |
+ "optional_enumeration": { |
+ "$ref": "Enumeration", |
+ "optional": true |
+ } |
+ } |
+ }, |
+ { |
"id": "OptionalEnumType", |
"type": "object", |
"properties": { |
@@ -43,6 +60,22 @@ |
] |
}, |
{ |
+ "name": "takesEnumAsType", |
+ "type": "function", |
+ "description": "Takes an enum type as its parameter.", |
+ "parameters": [ |
+ { |
+ "name": "enumeration", |
+ "$ref": "Enumeration" |
+ }, |
+ { |
+ "name": "callback", |
+ "type": "function", |
+ "parameters": [] |
+ } |
+ ] |
+ }, |
+ { |
"name": "returnsEnum", |
"type": "function", |
"description": "Returns an enum through the callback", |
@@ -61,6 +94,23 @@ |
] |
}, |
{ |
+ "name": "returnsEnumAsType", |
+ "type": "function", |
+ "description": "Returns an enum through the callback", |
+ "parameters": [ |
+ { |
+ "name": "callback", |
+ "type": "function", |
+ "parameters": [ |
+ { |
+ "name": "enumeration", |
+ "$ref": "Enumeration" |
+ } |
+ ] |
+ } |
+ ] |
+ }, |
+ { |
"name": "returnsTwoEnums", |
"type": "function", |
"description": "Returns two enums through the callback", |