| { |
| "tests": [ |
| { |
| "description": "create: complex", |
| "comment": "A call to a write method with complicated input data.", |
| "create": { |
| "docRefPath": "projects/projectID/databases/(default)/documents/C/d", |
| "jsonData": "{\"a\": [1, 2.5], \"b\": {\"c\": [\"three\", {\"d\": true}]}}", |
| "request": { |
| "database": "projects/projectID/databases/(default)", |
| "writes": [ |
| { |
| "update": { |
| "name": "projects/projectID/databases/(default)/documents/C/d", |
| "fields": { |
| "a": { |
| "arrayValue": { |
| "values": [ |
| { |
| "integerValue": "1" |
| }, |
| { |
| "doubleValue": 2.5 |
| } |
| ] |
| } |
| }, |
| "b": { |
| "mapValue": { |
| "fields": { |
| "c": { |
| "arrayValue": { |
| "values": [ |
| { |
| "stringValue": "three" |
| }, |
| { |
| "mapValue": { |
| "fields": { |
| "d": { |
| "booleanValue": true |
| } |
| } |
| } |
| } |
| ] |
| } |
| } |
| } |
| } |
| } |
| } |
| }, |
| "currentDocument": { |
| "exists": false |
| } |
| } |
| ] |
| } |
| } |
| } |
| ] |
| } |