Skip to content

Commit c79afde

Browse files
committed
test: update ng generate e2e calls to ng generate private-e2e.
1 parent 62877bd commit c79afde

File tree

5 files changed

+16
-8
lines changed

5 files changed

+16
-8
lines changed

packages/schematics/angular/e2e/index_spec.ts

+12-4
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ describe('Application Schematic', () => {
4949
});
5050

5151
it('should create all files of e2e in an application', async () => {
52-
const tree = await schematicRunner.runSchematic('e2e', defaultOptions, applicationTree);
52+
const tree = await schematicRunner.runSchematic('private-e2e', defaultOptions, applicationTree);
5353

5454
const files = tree.files;
5555
expect(files).toEqual(
@@ -64,15 +64,23 @@ describe('Application Schematic', () => {
6464

6565
describe('workspace config', () => {
6666
it('should add e2e targets for the app', async () => {
67-
const tree = await schematicRunner.runSchematic('e2e', defaultOptions, applicationTree);
67+
const tree = await schematicRunner.runSchematic(
68+
'private-e2e',
69+
defaultOptions,
70+
applicationTree,
71+
);
6872

6973
const workspace = JSON.parse(tree.readContent('/angular.json'));
7074
const targets = workspace.projects.foo.architect;
7175
expect(targets.e2e).toBeDefined();
7276
});
7377

7478
it('should set the e2e options', async () => {
75-
const tree = await schematicRunner.runSchematic('e2e', defaultOptions, applicationTree);
79+
const tree = await schematicRunner.runSchematic(
80+
'private-e2e',
81+
defaultOptions,
82+
applicationTree,
83+
);
7684

7785
const workspace = JSON.parse(tree.readContent('/angular.json'));
7886
const { options, configurations } = workspace.projects.foo.architect.e2e;
@@ -82,7 +90,7 @@ describe('Application Schematic', () => {
8290
});
8391

8492
it('should add an e2e script in package.json', async () => {
85-
const tree = await schematicRunner.runSchematic('e2e', defaultOptions, applicationTree);
93+
const tree = await schematicRunner.runSchematic('private-e2e', defaultOptions, applicationTree);
8694

8795
const pkg = JSON.parse(tree.readContent('/package.json'));
8896
expect(pkg.scripts['e2e']).toBe('ng e2e');

tests/legacy-cli/e2e/tests/build/jit-ngmodule.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { updateJsonFile, useCIChrome, useCIDefaults } from '../../utils/project'
44

55
export default async function () {
66
await ng('generate', 'app', 'test-project-two', '--no-standalone', '--skip-install');
7-
await ng('generate', 'e2e', '--related-app-name=test-project-two');
7+
await ng('generate', 'private-e2e', '--related-app-name=test-project-two');
88

99
// Setup testing to use CI Chrome.
1010
await useCIChrome('test-project-two', './projects/test-project-two/e2e');

tests/legacy-cli/e2e/tests/build/server-rendering/express-engine-ngmodule.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export default async function () {
1616
await rimraf('node_modules/@angular/ssr');
1717

1818
await ng('generate', 'app', 'test-project-two', '--no-standalone', '--skip-install');
19-
await ng('generate', 'e2e', '--related-app-name=test-project-two');
19+
await ng('generate', 'private-e2e', '--related-app-name=test-project-two');
2020

2121
// Setup testing to use CI Chrome.
2222
await useCIChrome('test-project-two', 'projects/test-project-two/e2e/');

tests/legacy-cli/e2e/tests/update/update.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ export default async function () {
7272
await ng('update', '@angular/cli', ...extraUpdateArgs);
7373

7474
// Generate E2E setup
75-
await ng('generate', 'e2e', '--related-app-name=fifteen-project');
75+
await ng('generate', 'private-e2e', '--related-app-name=fifteen-project');
7676

7777
// Setup testing to use CI Chrome.
7878
await useCIChrome('fifteen-project', './');

tests/legacy-cli/e2e/utils/project.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ export async function prepareProjectForE2e(name: string) {
5151

5252
console.log(`Project ${name} created... Installing packages.`);
5353
await installWorkspacePackages();
54-
await ng('generate', 'e2e', '--related-app-name', name);
54+
await ng('generate', 'private-e2e', '--related-app-name', name);
5555

5656
await useCIChrome(name, 'e2e');
5757
await useCIChrome(name, '');

0 commit comments

Comments
 (0)