{
"$schema": "https://raw.githubusercontent.com/CatConfLang/ccl-test-data/v0.6.0/schemas/generated-format.json",
"tests": [
{
"behaviors": [],
"expected": {
"count": 2,
"entries": [
{
"key": "key",
"value": "value"
},
{
"key": "nested",
"value": "\n sub = val"
}
]
},
"features": [],
"functions": [
"parse"
],
"inputs": [
"key = value\nnested =\n sub = val"
],
"name": "round_trip_basic_parse",
"source_test": "round_trip_basic",
"validation": "parse",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": "key = value\nnested = \n sub = val"
},
"features": [],
"functions": [
"print"
],
"inputs": [
"key = value\nnested =\n sub = val"
],
"name": "round_trip_basic_print",
"source_test": "round_trip_basic",
"validation": "print",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": true
},
"features": [],
"functions": [
"parse",
"print"
],
"inputs": [
"key = value\nnested =\n sub = val"
],
"name": "round_trip_basic_round_trip",
"source_test": "round_trip_basic",
"validation": "round_trip",
"variants": []
},
{
"behaviors": [
"toplevel_indent_strip"
],
"conflicts": {
"behaviors": [
"toplevel_indent_preserve"
]
},
"expected": {
"count": 1,
"entries": [
{
"key": "key",
"value": "value \n nested = \n sub = val"
}
]
},
"features": [
"whitespace"
],
"functions": [
"parse"
],
"inputs": [
" key = value \n nested = \n sub = val "
],
"name": "round_trip_whitespace_normalization_parse",
"source_test": "round_trip_whitespace_normalization",
"validation": "parse",
"variants": [
"reference_compliant"
]
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": true
},
"features": [
"whitespace"
],
"functions": [
"parse",
"print"
],
"inputs": [
" key = value \n nested = \n sub = val "
],
"name": "round_trip_whitespace_normalization_round_trip",
"source_test": "round_trip_whitespace_normalization",
"validation": "round_trip",
"variants": [
"reference_compliant"
]
},
{
"behaviors": [
"toplevel_indent_preserve"
],
"conflicts": {
"behaviors": [
"toplevel_indent_strip"
]
},
"expected": {
"count": 2,
"entries": [
{
"key": "key",
"value": "value"
},
{
"key": "nested",
"value": "\n sub = val"
}
]
},
"features": [
"whitespace"
],
"functions": [
"parse"
],
"inputs": [
" key = value \n nested = \n sub = val "
],
"name": "round_trip_whitespace_normalization_toplevel_indent_preserve_parse",
"source_test": "round_trip_whitespace_normalization_toplevel_indent_preserve",
"validation": "parse",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": true
},
"features": [
"whitespace"
],
"functions": [
"parse",
"print"
],
"inputs": [
" key = value \n nested = \n sub = val "
],
"name": "round_trip_whitespace_normalization_toplevel_indent_preserve_round_trip",
"source_test": "round_trip_whitespace_normalization_toplevel_indent_preserve",
"validation": "round_trip",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 3,
"entries": [
{
"key": "",
"value": "item1"
},
{
"key": "",
"value": "item2"
},
{
"key": "regular",
"value": "value"
}
]
},
"features": [
"empty_keys"
],
"functions": [
"parse"
],
"inputs": [
"= item1\n= item2\nregular = value"
],
"name": "round_trip_empty_keys_lists_parse",
"source_test": "round_trip_empty_keys_lists",
"validation": "parse",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": "= item1\n= item2\nregular = value"
},
"features": [
"empty_keys"
],
"functions": [
"print"
],
"inputs": [
"= item1\n= item2\nregular = value"
],
"name": "round_trip_empty_keys_lists_print",
"source_test": "round_trip_empty_keys_lists",
"validation": "print",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": true
},
"features": [
"empty_keys"
],
"functions": [
"parse",
"print"
],
"inputs": [
"= item1\n= item2\nregular = value"
],
"name": "round_trip_empty_keys_lists_round_trip",
"source_test": "round_trip_empty_keys_lists",
"validation": "round_trip",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"entries": [
{
"key": "config",
"value": "\n host = localhost\n port = 8080\n db =\n name = mydb\n user = admin"
}
]
},
"features": [],
"functions": [
"parse"
],
"inputs": [
"config =\n host = localhost\n port = 8080\n db =\n name = mydb\n user = admin"
],
"name": "round_trip_nested_structures_parse",
"source_test": "round_trip_nested_structures",
"validation": "parse",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": "config = \n host = localhost\n port = 8080\n db =\n name = mydb\n user = admin"
},
"features": [],
"functions": [
"print"
],
"inputs": [
"config =\n host = localhost\n port = 8080\n db =\n name = mydb\n user = admin"
],
"name": "round_trip_nested_structures_print",
"source_test": "round_trip_nested_structures",
"validation": "print",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": true
},
"features": [],
"functions": [
"parse",
"print"
],
"inputs": [
"config =\n host = localhost\n port = 8080\n db =\n name = mydb\n user = admin"
],
"name": "round_trip_nested_structures_round_trip",
"source_test": "round_trip_nested_structures",
"validation": "round_trip",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"entries": [
{
"key": "script",
"value": "\n #!/bin/bash\n echo hello\n exit 0"
}
]
},
"features": [
"multiline"
],
"functions": [
"parse"
],
"inputs": [
"script =\n #!/bin/bash\n echo hello\n exit 0"
],
"name": "round_trip_multiline_values_parse",
"source_test": "round_trip_multiline_values",
"validation": "parse",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": "script = \n #!/bin/bash\n echo hello\n exit 0"
},
"features": [
"multiline"
],
"functions": [
"print"
],
"inputs": [
"script =\n #!/bin/bash\n echo hello\n exit 0"
],
"name": "round_trip_multiline_values_print",
"source_test": "round_trip_multiline_values",
"validation": "print",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": true
},
"features": [
"multiline"
],
"functions": [
"parse",
"print"
],
"inputs": [
"script =\n #!/bin/bash\n echo hello\n exit 0"
],
"name": "round_trip_multiline_values_round_trip",
"source_test": "round_trip_multiline_values",
"validation": "round_trip",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 5,
"entries": [
{
"key": "name",
"value": "Alice"
},
{
"key": "",
"value": "first item"
},
{
"key": "config",
"value": "\n port = 3000"
},
{
"key": "",
"value": "second item"
},
{
"key": "final",
"value": "value"
}
]
},
"features": [
"empty_keys"
],
"functions": [
"parse"
],
"inputs": [
"name = Alice\n= first item\nconfig =\n port = 3000\n= second item\nfinal = value"
],
"name": "round_trip_mixed_content_parse",
"source_test": "round_trip_mixed_content",
"validation": "parse",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": "name = Alice\n= first item\nconfig = \n port = 3000\n= second item\nfinal = value"
},
"features": [
"empty_keys"
],
"functions": [
"print"
],
"inputs": [
"name = Alice\n= first item\nconfig =\n port = 3000\n= second item\nfinal = value"
],
"name": "round_trip_mixed_content_print",
"source_test": "round_trip_mixed_content",
"validation": "print",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": true
},
"features": [
"empty_keys"
],
"functions": [
"parse",
"print"
],
"inputs": [
"name = Alice\n= first item\nconfig =\n port = 3000\n= second item\nfinal = value"
],
"name": "round_trip_mixed_content_round_trip",
"source_test": "round_trip_mixed_content",
"validation": "round_trip",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"entries": [
{
"key": "app",
"value": "\n = item1\n config =\n = nested_item\n db =\n host = localhost\n = db_item\n = item2"
}
]
},
"features": [
"empty_keys"
],
"functions": [
"parse"
],
"inputs": [
"app =\n = item1\n config =\n = nested_item\n db =\n host = localhost\n = db_item\n = item2"
],
"name": "round_trip_complex_nesting_parse",
"source_test": "round_trip_complex_nesting",
"validation": "parse",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": "app = \n = item1\n config =\n = nested_item\n db =\n host = localhost\n = db_item\n = item2"
},
"features": [
"empty_keys"
],
"functions": [
"print"
],
"inputs": [
"app =\n = item1\n config =\n = nested_item\n db =\n host = localhost\n = db_item\n = item2"
],
"name": "round_trip_complex_nesting_print",
"source_test": "round_trip_complex_nesting",
"validation": "print",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": true
},
"features": [
"empty_keys"
],
"functions": [
"parse",
"print"
],
"inputs": [
"app =\n = item1\n config =\n = nested_item\n db =\n host = localhost\n = db_item\n = item2"
],
"name": "round_trip_complex_nesting_round_trip",
"source_test": "round_trip_complex_nesting",
"validation": "round_trip",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"entries": [
{
"key": "level1",
"value": "\n level2 =\n level3 =\n level4 =\n deep = value\n = deep_item"
}
]
},
"features": [
"empty_keys"
],
"functions": [
"parse"
],
"inputs": [
"level1 =\n level2 =\n level3 =\n level4 =\n deep = value\n = deep_item"
],
"name": "round_trip_deeply_nested_parse",
"source_test": "round_trip_deeply_nested",
"validation": "parse",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": "level1 = \n level2 =\n level3 =\n level4 =\n deep = value\n = deep_item"
},
"features": [
"empty_keys"
],
"functions": [
"print"
],
"inputs": [
"level1 =\n level2 =\n level3 =\n level4 =\n deep = value\n = deep_item"
],
"name": "round_trip_deeply_nested_print",
"source_test": "round_trip_deeply_nested",
"validation": "print",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": true
},
"features": [
"empty_keys"
],
"functions": [
"parse",
"print"
],
"inputs": [
"level1 =\n level2 =\n level3 =\n level4 =\n deep = value\n = deep_item"
],
"name": "round_trip_deeply_nested_round_trip",
"source_test": "round_trip_deeply_nested",
"validation": "round_trip",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 2,
"entries": [
{
"key": "empty_section",
"value": ""
},
{
"key": "other",
"value": "value"
}
]
},
"features": [
"empty_keys",
"multiline"
],
"functions": [
"parse"
],
"inputs": [
"empty_section =\n\nother = value"
],
"name": "round_trip_empty_multiline_parse",
"source_test": "round_trip_empty_multiline",
"validation": "parse",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": "empty_section = \nother = value"
},
"features": [
"empty_keys",
"multiline"
],
"functions": [
"print"
],
"inputs": [
"empty_section =\n\nother = value"
],
"name": "round_trip_empty_multiline_print",
"source_test": "round_trip_empty_multiline",
"validation": "print",
"variants": []
},
{
"behaviors": [],
"expected": {
"count": 1,
"value": true
},
"features": [
"empty_keys",
"multiline"
],
"functions": [
"parse",
"print"
],
"inputs": [
"empty_section =\n\nother = value"
],
"name": "round_trip_empty_multiline_round_trip",
"source_test": "round_trip_empty_multiline",
"validation": "round_trip",
"variants": []
}
]
}