mirror of
https://github.com/github/codeql.git
synced 2026-05-01 19:55:15 +02:00
JS: add integration test for diagnostic messages
This commit is contained in:
@@ -0,0 +1 @@
|
||||
4 %%% 5
|
||||
@@ -0,0 +1,21 @@
|
||||
{
|
||||
"location": {
|
||||
"endColumn": 4,
|
||||
"endLine": 1,
|
||||
"file": "bad.js",
|
||||
"startColumn": 4,
|
||||
"startLine": 1
|
||||
},
|
||||
"markdownMessage": "A parse error occurred: Unexpected token. Check the syntax of the file. If the file is invalid, correct the error or exclude the file from analysis.",
|
||||
"severity": "warning",
|
||||
"source": {
|
||||
"extractorName": "javascript",
|
||||
"id": "javascript/parse-error",
|
||||
"name": "Parse error"
|
||||
},
|
||||
"visibility": {
|
||||
"cliSummaryTable": true,
|
||||
"statusPage": true,
|
||||
"telemetry": true
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
import os
|
||||
from create_database_utils import *
|
||||
from diagnostics_test_utils import *
|
||||
|
||||
run_codeql_database_create([], lang="javascript", runFunction = runSuccessfully, db = None)
|
||||
|
||||
check_diagnostics()
|
||||
3
javascript/ql/integration-tests/all-platforms/qlpack.yml
Normal file
3
javascript/ql/integration-tests/all-platforms/qlpack.yml
Normal file
@@ -0,0 +1,3 @@
|
||||
dependencies:
|
||||
codeql/javascript-all: '*'
|
||||
codeql/javascript-queries: '*'
|
||||
Reference in New Issue
Block a user