diff options
Diffstat (limited to 'tests/specs/lint/jsx')
-rw-r--r-- | tests/specs/lint/jsx/__test__.jsonc | 16 | ||||
-rw-r--r-- | tests/specs/lint/jsx/main.jsx | 1 | ||||
-rw-r--r-- | tests/specs/lint/jsx/main_unix.out | 12 | ||||
-rw-r--r-- | tests/specs/lint/jsx/main_windows.out | 12 |
4 files changed, 41 insertions, 0 deletions
diff --git a/tests/specs/lint/jsx/__test__.jsonc b/tests/specs/lint/jsx/__test__.jsonc new file mode 100644 index 000000000..42dda30a5 --- /dev/null +++ b/tests/specs/lint/jsx/__test__.jsonc @@ -0,0 +1,16 @@ +{ + "steps": [ + { + "if": "windows", + "args": "lint main.jsx", + "output": "main_windows.out", + "exitCode": 1 + }, + { + "if": "unix", + "args": "lint main.jsx", + "output": "main_unix.out", + "exitCode": 1 + } + ] +} diff --git a/tests/specs/lint/jsx/main.jsx b/tests/specs/lint/jsx/main.jsx new file mode 100644 index 000000000..625e7d430 --- /dev/null +++ b/tests/specs/lint/jsx/main.jsx @@ -0,0 +1 @@ +const data = <div>hello</div>; diff --git a/tests/specs/lint/jsx/main_unix.out b/tests/specs/lint/jsx/main_unix.out new file mode 100644 index 000000000..08816e9fe --- /dev/null +++ b/tests/specs/lint/jsx/main_unix.out @@ -0,0 +1,12 @@ +error[no-unused-vars]: `data` is never used + --> [WILDCARD]lint/jsx/main.jsx:1:7 + | +1 | const data = <div>hello</div>; + | ^^^^ + = hint: If this is intentional, prefix it with an underscore like `_data` + + docs: https://lint.deno.land/rules/no-unused-vars + + +Found 1 problem +Checked 1 file diff --git a/tests/specs/lint/jsx/main_windows.out b/tests/specs/lint/jsx/main_windows.out new file mode 100644 index 000000000..ec6ebecad --- /dev/null +++ b/tests/specs/lint/jsx/main_windows.out @@ -0,0 +1,12 @@ +error[no-unused-vars]: `data` is never used + --> [WILDCARD]lint\jsx\main.jsx:1:7 + | +1 | const data = <div>hello</div>; + | ^^^^ + = hint: If this is intentional, prefix it with an underscore like `_data` + + docs: https://lint.deno.land/rules/no-unused-vars + + +Found 1 problem +Checked 1 file |