test: Add JSONP notation test case for JSON Repair operation

- Add test case to verify JSONP callback wrapper removal
- Validates that callback({name: John, age: 30}) becomes {name: John, age: 30}
- Ensures comprehensive coverage of jsonrepair library features
- Total test cases now: 12 (previously 11)
This commit is contained in:
maojunxyz 2025-08-08 18:04:36 +08:00
parent 07fbc1eda0
commit dd21b72193

View File

@ -161,4 +161,15 @@ TestRegister.addTests([
}, },
], ],
}, },
{
name: "JSON Repair: JSONP notation",
input: 'callback({"name": "John", "age": 30})',
expectedOutput: '{"name": "John", "age": 30}',
recipeConfig: [
{
op: "JSON Repair",
args: [],
},
],
},
]); ]);