summaryrefslogtreecommitdiff
path: root/tests/specs/lint/stdin_json
diff options
context:
space:
mode:
Diffstat (limited to 'tests/specs/lint/stdin_json')
-rw-r--r--tests/specs/lint/stdin_json/__test__.jsonc5
-rw-r--r--tests/specs/lint/stdin_json/expected_from_stdin_json.out24
-rw-r--r--tests/specs/lint/stdin_json/main.ts1
3 files changed, 30 insertions, 0 deletions
diff --git a/tests/specs/lint/stdin_json/__test__.jsonc b/tests/specs/lint/stdin_json/__test__.jsonc
new file mode 100644
index 000000000..a777147f6
--- /dev/null
+++ b/tests/specs/lint/stdin_json/__test__.jsonc
@@ -0,0 +1,5 @@
+{
+ "args": "lint --json main.ts",
+ "output": "expected_from_stdin_json.out",
+ "exitCode": 1
+}
diff --git a/tests/specs/lint/stdin_json/expected_from_stdin_json.out b/tests/specs/lint/stdin_json/expected_from_stdin_json.out
new file mode 100644
index 000000000..5788248aa
--- /dev/null
+++ b/tests/specs/lint/stdin_json/expected_from_stdin_json.out
@@ -0,0 +1,24 @@
+{
+ "version": 1,
+ "diagnostics": [
+ {
+ "filename": "[WILDCARD]main.ts",
+ "range": {
+ "start": {
+ "line": 1,
+ "col": 8,
+ "bytePos": 8
+ },
+ "end": {
+ "line": 1,
+ "col": 11,
+ "bytePos": 11
+ }
+ },
+ "message": "`any` type is not allowed",
+ "code": "no-explicit-any",
+ "hint": [WILDCARD]
+ }
+ ],
+ "errors": []
+}
diff --git a/tests/specs/lint/stdin_json/main.ts b/tests/specs/lint/stdin_json/main.ts
new file mode 100644
index 000000000..8abcd79b8
--- /dev/null
+++ b/tests/specs/lint/stdin_json/main.ts
@@ -0,0 +1 @@
+let _a: any;