This commit is contained in:
41
fixtures/code/code_shebang_detection.json
Normal file
41
fixtures/code/code_shebang_detection.json
Normal file
@@ -0,0 +1,41 @@
|
||||
{
|
||||
"id": "code_shebang_detection",
|
||||
"category": "code",
|
||||
"description": "Test language detection from shebang line via bytes input",
|
||||
"tags": [
|
||||
"code",
|
||||
"shebang",
|
||||
"tree-sitter"
|
||||
],
|
||||
"call": "extract_file_sync",
|
||||
"input": {
|
||||
"path": "code/script.sh",
|
||||
"mime_type": "text/x-source-code"
|
||||
},
|
||||
"assertions": [
|
||||
{
|
||||
"type": "equals",
|
||||
"field": "mime_type",
|
||||
"value": "text/x-source-code"
|
||||
},
|
||||
{
|
||||
"type": "min_length",
|
||||
"field": "content",
|
||||
"value": 10
|
||||
},
|
||||
{
|
||||
"type": "contains_all",
|
||||
"field": "content",
|
||||
"values": [
|
||||
"build",
|
||||
"clean"
|
||||
]
|
||||
}
|
||||
],
|
||||
"skip": {
|
||||
"languages": [
|
||||
"wasm"
|
||||
],
|
||||
"reason": "WASM cannot access filesystem; use extractBytes with file content instead"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user