diff options
Diffstat (limited to 'tests/specs/publish/workspace')
-rw-r--r-- | tests/specs/publish/workspace/__test__.jsonc | 10 | ||||
-rw-r--r-- | tests/specs/publish/workspace/bar/deno.json | 7 | ||||
-rw-r--r-- | tests/specs/publish/workspace/bar/mod.ts | 3 | ||||
-rw-r--r-- | tests/specs/publish/workspace/deno.json | 6 | ||||
-rw-r--r-- | tests/specs/publish/workspace/foo/deno.json | 10 | ||||
-rw-r--r-- | tests/specs/publish/workspace/foo/mod.ts | 5 | ||||
-rw-r--r-- | tests/specs/publish/workspace/workspace.out | 12 | ||||
-rw-r--r-- | tests/specs/publish/workspace/workspace_individual.out | 6 |
8 files changed, 59 insertions, 0 deletions
diff --git a/tests/specs/publish/workspace/__test__.jsonc b/tests/specs/publish/workspace/__test__.jsonc new file mode 100644 index 000000000..7b1c04d56 --- /dev/null +++ b/tests/specs/publish/workspace/__test__.jsonc @@ -0,0 +1,10 @@ +{ + "steps": [{ + "args": "publish --token 'sadfasdf'", + "output": "workspace.out" + }, { + "cwd": "./bar", + "args": "publish --token 'sadfasdf'", + "output": "workspace_individual.out" + }] +} diff --git a/tests/specs/publish/workspace/bar/deno.json b/tests/specs/publish/workspace/bar/deno.json new file mode 100644 index 000000000..213a7cec6 --- /dev/null +++ b/tests/specs/publish/workspace/bar/deno.json @@ -0,0 +1,7 @@ +{ + "name": "@foo/bar", + "version": "1.0.0", + "exports": { + ".": "./mod.ts" + } +} diff --git a/tests/specs/publish/workspace/bar/mod.ts b/tests/specs/publish/workspace/bar/mod.ts new file mode 100644 index 000000000..8d9b8a22a --- /dev/null +++ b/tests/specs/publish/workspace/bar/mod.ts @@ -0,0 +1,3 @@ +export function add(a: number, b: number): number { + return a + b; +} diff --git a/tests/specs/publish/workspace/deno.json b/tests/specs/publish/workspace/deno.json new file mode 100644 index 000000000..57602aab5 --- /dev/null +++ b/tests/specs/publish/workspace/deno.json @@ -0,0 +1,6 @@ +{ + "workspaces": [ + "foo", + "bar" + ] +} diff --git a/tests/specs/publish/workspace/foo/deno.json b/tests/specs/publish/workspace/foo/deno.json new file mode 100644 index 000000000..79563d36c --- /dev/null +++ b/tests/specs/publish/workspace/foo/deno.json @@ -0,0 +1,10 @@ +{ + "name": "@foo/foo", + "version": "1.0.0", + "exports": { + ".": "./mod.ts" + }, + "imports": { + "bar": "jsr:@foo/bar@1" + } +} diff --git a/tests/specs/publish/workspace/foo/mod.ts b/tests/specs/publish/workspace/foo/mod.ts new file mode 100644 index 000000000..adf584463 --- /dev/null +++ b/tests/specs/publish/workspace/foo/mod.ts @@ -0,0 +1,5 @@ +import * as bar from "bar"; + +export function add(a: number, b: number): number { + return bar.add(a, b); +} diff --git a/tests/specs/publish/workspace/workspace.out b/tests/specs/publish/workspace/workspace.out new file mode 100644 index 000000000..8c57bc2dd --- /dev/null +++ b/tests/specs/publish/workspace/workspace.out @@ -0,0 +1,12 @@ +Publishing a workspace... +Check file:///[WILDCARD]/foo/mod.ts +Check file:///[WILDCARD]/bar/mod.ts +Checking for slow types in the public API... +Check file:///[WILDCARD]/foo/mod.ts +Check file:///[WILDCARD]/bar/mod.ts +Publishing @foo/bar@1.0.0 ... +Successfully published @foo/bar@1.0.0 +Visit http://127.0.0.1:4250/@foo/bar@1.0.0 for details +Publishing @foo/foo@1.0.0 ... +Successfully published @foo/foo@1.0.0 +Visit http://127.0.0.1:4250/@foo/foo@1.0.0 for details diff --git a/tests/specs/publish/workspace/workspace_individual.out b/tests/specs/publish/workspace/workspace_individual.out new file mode 100644 index 000000000..edb6b53aa --- /dev/null +++ b/tests/specs/publish/workspace/workspace_individual.out @@ -0,0 +1,6 @@ +Check file:///[WILDCARD]/bar/mod.ts +Checking for slow types in the public API... +Check file:///[WILDCARD]/bar/mod.ts +Publishing @foo/bar@1.0.0 ... +Successfully published @foo/bar@1.0.0 +Visit http://127.0.0.1:4250/@foo/bar@1.0.0 for details |