| { |
| "tests": [ |
| { |
| "description": "create: ServerTimestamp with data", |
| "comment": "A key with the special ServerTimestamp sentinel is removed from\nthe fields in the update operation. Instead it appears in update transforms.\nNote that in these tests, the string \"ServerTimestamp\" should be replaced with the\nspecial ServerTimestamp value.", |
| "create": { |
| "docRefPath": "projects/projectID/databases/(default)/documents/C/d", |
| "jsonData": "{\"a\": 1, \"b\": \"ServerTimestamp\"}", |
| "request": { |
| "database": "projects/projectID/databases/(default)", |
| "writes": [ |
| { |
| "update": { |
| "name": "projects/projectID/databases/(default)/documents/C/d", |
| "fields": { |
| "a": { |
| "integerValue": "1" |
| } |
| } |
| }, |
| "updateTransforms": [ |
| { |
| "fieldPath": "b", |
| "setToServerValue": "REQUEST_TIME" |
| } |
| ], |
| "currentDocument": { |
| "exists": false |
| } |
| } |
| ] |
| } |
| } |
| } |
| ] |
| } |