diff options
Diffstat (limited to 'tests/specs')
-rw-r--r-- | tests/specs/lint/jsr_pkg_no_version/__test__.jsonc | 5 | ||||
-rw-r--r-- | tests/specs/lint/jsr_pkg_no_version/deno.json | 4 | ||||
-rw-r--r-- | tests/specs/lint/jsr_pkg_no_version/lint.out | 14 | ||||
-rw-r--r-- | tests/specs/lint/jsr_pkg_no_version/mod.ts | 3 |
4 files changed, 26 insertions, 0 deletions
diff --git a/tests/specs/lint/jsr_pkg_no_version/__test__.jsonc b/tests/specs/lint/jsr_pkg_no_version/__test__.jsonc new file mode 100644 index 000000000..d1783f1dc --- /dev/null +++ b/tests/specs/lint/jsr_pkg_no_version/__test__.jsonc @@ -0,0 +1,5 @@ +{ + "args": "lint", + "output": "lint.out", + "exitCode": 1 +} diff --git a/tests/specs/lint/jsr_pkg_no_version/deno.json b/tests/specs/lint/jsr_pkg_no_version/deno.json new file mode 100644 index 000000000..50d49ffb6 --- /dev/null +++ b/tests/specs/lint/jsr_pkg_no_version/deno.json @@ -0,0 +1,4 @@ +{ + "name": "@scope/pkg", + "exports": "./mod.ts" +} diff --git a/tests/specs/lint/jsr_pkg_no_version/lint.out b/tests/specs/lint/jsr_pkg_no_version/lint.out new file mode 100644 index 000000000..208499590 --- /dev/null +++ b/tests/specs/lint/jsr_pkg_no_version/lint.out @@ -0,0 +1,14 @@ +error[no-slow-types]: missing explicit return type in the public API + --> [WILDLINE]:1:17 + | +1 | export function test() { + | ^^^^ this function is missing an explicit return type + | + = hint: add an explicit return type to the function + + info: all functions in the public API must have an explicit return type + docs: https://jsr.io/go/slow-type-missing-explicit-return-type + + +Found 1 problem +Checked 1 file diff --git a/tests/specs/lint/jsr_pkg_no_version/mod.ts b/tests/specs/lint/jsr_pkg_no_version/mod.ts new file mode 100644 index 000000000..02abbfe2f --- /dev/null +++ b/tests/specs/lint/jsr_pkg_no_version/mod.ts @@ -0,0 +1,3 @@ +export function test() { + return 1 + 2; +} |