| 12345678910111213141516171819202122232425262728293031323334353637 |
- {
- "name": "verify-datetime",
- "nodes": [
- {"id": "n1", "name": "Trigger", "type": "click-trigger", "position": {"x": 0, "y": 0}, "config": {}},
- {"id": "n2", "name": "Fixture", "type": "code", "position": {"x": 0, "y": 100},
- "config": {"code": "return { when: '2026-01-15T10:30:00Z', later: '2026-01-20T10:30:00Z' };"}},
- {"id": "n3", "name": "FormatUTC", "type": "datetime", "position": {"x": -150, "y": 200},
- "config": {"operation": "format", "inputField": "data.result.when", "format": "YYYY-MM-DD HH:mm:ss", "outputField": "value"}},
- {"id": "n4", "name": "FormatOffset", "type": "datetime", "position": {"x": -50, "y": 200},
- "config": {"operation": "format", "inputField": "data.result.when", "format": "YYYY-MM-DD HH:mm:ss", "offset": "+02:00", "outputField": "value"}},
- {"id": "n5", "name": "AddDays", "type": "datetime", "position": {"x": 50, "y": 200},
- "config": {"operation": "add", "inputField": "data.result.when", "amount": 3, "unit": "days", "format": "YYYY-MM-DD", "outputField": "value"}},
- {"id": "n6", "name": "Diff", "type": "datetime", "position": {"x": 150, "y": 200},
- "config": {"operation": "diff", "inputField": "data.result.later", "secondField": "data.result.when", "unit": "days", "outputField": "value"}},
- {"id": "n7", "name": "Now", "type": "datetime", "position": {"x": 250, "y": 200},
- "config": {"operation": "now"}},
- {"id": "n8", "name": "FormatMaxOffset", "type": "datetime", "position": {"x": 350, "y": 200},
- "config": {"operation": "format", "inputField": "data.result.when", "format": "YYYY-MM-DD HH:mm:ss", "offset": "+14:00", "outputField": "value"}}
- ],
- "connections": [
- {"sourceNodeId": "n1", "sourceOutput": "main", "targetNodeId": "n2", "targetInput": "data"},
- {"sourceNodeId": "n2", "sourceOutput": "main", "targetNodeId": "n3", "targetInput": "data"},
- {"sourceNodeId": "n2", "sourceOutput": "main", "targetNodeId": "n4", "targetInput": "data"},
- {"sourceNodeId": "n2", "sourceOutput": "main", "targetNodeId": "n5", "targetInput": "data"},
- {"sourceNodeId": "n2", "sourceOutput": "main", "targetNodeId": "n6", "targetInput": "data"},
- {"sourceNodeId": "n2", "sourceOutput": "main", "targetNodeId": "n7", "targetInput": "data"},
- {"sourceNodeId": "n2", "sourceOutput": "main", "targetNodeId": "n8", "targetInput": "data"}
- ],
- "expect": {
- "n3": {"status": "completed", "output": {"value": "2026-01-15 10:30:00"}},
- "n4": {"status": "completed", "output": {"value": "2026-01-15 12:30:00"}},
- "n5": {"status": "completed", "output": {"value": "2026-01-18"}},
- "n6": {"status": "completed", "output": {"value": 5}},
- "n7": {"status": "completed"},
- "n8": {"status": "completed", "output": {"value": "2026-01-16 00:30:00"}}
- }
- }
|