mono/packages/xblox/tests/fixtures/switch-case.json
2026-04-07 19:41:32 +02:00

29 lines
610 B
JSON

{
"version": 1,
"context": { "mode": 2 },
"roots": [
{
"kind": "switch",
"variable": "mode",
"items": [
{
"kind": "case",
"comparator": "==",
"expression": "1",
"consequent": [{ "kind": "runScript", "method": "return 'one';" }]
},
{
"kind": "case",
"comparator": "==",
"expression": "2",
"consequent": [{ "kind": "runScript", "method": "return 'two';" }]
},
{
"kind": "switchDefault",
"consequent": [{ "kind": "runScript", "method": "return 'def';" }]
}
]
}
]
}