summaryrefslogtreecommitdiff
path: root/tests/specs/workspaces/lockfile/pkg
diff options
context:
space:
mode:
Diffstat (limited to 'tests/specs/workspaces/lockfile/pkg')
-rw-r--r--tests/specs/workspaces/lockfile/pkg/deno.jsonc8
-rw-r--r--tests/specs/workspaces/lockfile/pkg/mod.test.ts7
-rw-r--r--tests/specs/workspaces/lockfile/pkg/mod.ts5
3 files changed, 20 insertions, 0 deletions
diff --git a/tests/specs/workspaces/lockfile/pkg/deno.jsonc b/tests/specs/workspaces/lockfile/pkg/deno.jsonc
new file mode 100644
index 000000000..7bd6ab450
--- /dev/null
+++ b/tests/specs/workspaces/lockfile/pkg/deno.jsonc
@@ -0,0 +1,8 @@
+{
+ "name": "@scope/pkg",
+ "version": "1.0.0",
+ "exports": "./mod.ts",
+ "imports": {
+ "@denotest/add": "jsr:@denotest/add@1"
+ }
+}
diff --git a/tests/specs/workspaces/lockfile/pkg/mod.test.ts b/tests/specs/workspaces/lockfile/pkg/mod.test.ts
new file mode 100644
index 000000000..9e7a8c445
--- /dev/null
+++ b/tests/specs/workspaces/lockfile/pkg/mod.test.ts
@@ -0,0 +1,7 @@
+import { add } from "./mod.ts";
+
+Deno.test("should add", () => {
+ if (add(1, 2) !== 3) {
+ throw new Error("failed");
+ }
+});
diff --git a/tests/specs/workspaces/lockfile/pkg/mod.ts b/tests/specs/workspaces/lockfile/pkg/mod.ts
new file mode 100644
index 000000000..f69572b49
--- /dev/null
+++ b/tests/specs/workspaces/lockfile/pkg/mod.ts
@@ -0,0 +1,5 @@
+import * as denotestAdd from "@denotest/add";
+
+export function add(a: number, b: number) {
+ return denotestAdd.add(a, b);
+}