Skip to content

Commit

Permalink
test: cleanup deps
Browse files Browse the repository at this point in the history
  • Loading branch information
BioPhoton committed Nov 22, 2024
1 parent e73edc2 commit 88bf84c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 33 deletions.
9 changes: 1 addition & 8 deletions e2e/create-cli-e2e/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,6 @@
}
}
},
"implicitDependencies": [
"models",
"utils",
"core",
"cli",
"nx-plugin",
"create-cli"
],
"implicitDependencies": ["create-cli"],
"tags": ["scope:tooling", "type:e2e"]
}
28 changes: 4 additions & 24 deletions e2e/create-cli-e2e/tests/init.e2e.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,10 @@ describe('create-cli-inti', () => {

it('should execute package correctly over npm exec', async () => {
const cwd = join(testFileDir, 'npm-exec');
const userconfig = relative(cwd, join(workspaceRoot, '.npmrc'));
await createNpmWorkspace(cwd);
const { code, stdout } = await executeProcess({
command: 'npm',
args: [
'exec',
'@code-pushup/create-cli',
`--userconfig=${userconfig}`,
`--prefix=${dirname(userconfig)}`,
],
args: ['exec', '@code-pushup/create-cli'],
cwd,
});

Expand Down Expand Up @@ -60,18 +54,11 @@ describe('create-cli-inti', () => {

it('should execute package correctly over npm init', async () => {
const cwd = join(testFileDir, 'npm-init');
const userconfig = relative(cwd, join(workspaceRoot, '.npmrc'));

await createNpmWorkspace(cwd);

const { code, stdout } = await executeProcess({
command: 'npm',
args: [
'init',
'@code-pushup/cli',
`--userconfig=${userconfig}`,
`--prefix=${dirname(userconfig)}`,
],
args: ['init', '@code-pushup/cli'],
cwd,
});

Expand Down Expand Up @@ -102,25 +89,18 @@ describe('create-cli-inti', () => {

it('should produce an executable setup when running npm init', async () => {
const cwd = join(testFileDir, 'npm-init-executable');
const userconfig = relative(cwd, join(workspaceRoot, '.npmrc'));

await createNpmWorkspace(cwd);

await executeProcess({
command: 'npm',
args: [
'init',
'@code-pushup/cli',
`--userconfig=${userconfig}`,
`--prefix=${dirname(userconfig)}`,
],
args: ['init', '@code-pushup/cli'],
cwd,
});

await expect(
executeProcess({
command: 'npx',
args: ['@code-pushup/cli print-config', `--userconfig=${userconfig}`],
args: ['@code-pushup/cli print-config'],
cwd,
}),
)
Expand Down
2 changes: 1 addition & 1 deletion testing/test-nx-utils/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,5 @@
}
}
},
"tags": ["scope:tooling", "type:testing"]
"tags": ["scope:shared", "type:testing"]
}

0 comments on commit 88bf84c

Please sign in to comment.