Skip to content

fix(@schematics/angular): don't create e2e script when createApplication is false#16203

Merged
alan-agius4 merged 1 commit into
angular:masterfrom
timdeschryver:issue-13412
Aug 14, 2020
Merged

fix(@schematics/angular): don't create e2e script when createApplication is false#16203
alan-agius4 merged 1 commit into
angular:masterfrom
timdeschryver:issue-13412

Conversation

@timdeschryver
Copy link
Copy Markdown
Contributor

Bugfix for the ng new --createApplication=false command.
Currently, it creates an e2e script in package.json. This change will only add the script when the application is created.

Closes #13412

@clydin
Copy link
Copy Markdown
Member

clydin commented Nov 17, 2019

Thank you for the contribution.
However, I don’t think this is the correct approach for this.
If the E2E npm script should only be present when an application is added to the application, then I think that the application schematic should be adding it. This allows the workspace schematic to remain agnostic to the concept of an application.

@alan-agius4
Copy link
Copy Markdown
Collaborator

I also, do agree with @clydin

@timdeschryver
Copy link
Copy Markdown
Contributor Author

I agree that it's a valid point raised, I did it because I thought to treat it the same as the minimal flag.

I will push a commit later with the changes.
So the workspace schematic won't have the e2e script, but it will be added via the application schematic, right? Or does the workspace schematic remain as is, and will the application schematic remove the e2e script if needed?

@clydin
Copy link
Copy Markdown
Member

clydin commented Nov 17, 2019

I think the former (removing it from the workspace generation) would be the appropriate path.

@timdeschryver timdeschryver force-pushed the issue-13412 branch 3 times, most recently from f8e6ca7 to 67d8cd8 Compare November 17, 2019 20:05
@timdeschryver
Copy link
Copy Markdown
Contributor Author

Should this be part of the e2e schematic instead?

@alan-agius4
Copy link
Copy Markdown
Collaborator

Hi, @timdeschryver, sorry for taking us long to get back to you about this.

Should this be part of the e2e schematic instead?

Yes, I think that's the best approach.

@timdeschryver timdeschryver force-pushed the issue-13412 branch 2 times, most recently from 006b85e to a22106c Compare April 20, 2020 06:32
@timdeschryver
Copy link
Copy Markdown
Contributor Author

Should be ready for another review @alan-agius4
If there's something I can do, please let met know.

…ion is false

Bugfix for the ng new --createApplication=false command.
Currently, it creates an e2e script in package.json. This change will only add the script when the application is created.

Closes angular#13412
@alan-agius4 alan-agius4 added the target: patch This PR is targeted for the next patch release label Aug 14, 2020
@alan-agius4 alan-agius4 self-requested a review August 14, 2020 12:36
@alan-agius4
Copy link
Copy Markdown
Collaborator

Hi @timdeschryver, sorry for the delay on this. I rebased the PR and did some changes to get this in!

Thanks and sorry once again.

@alan-agius4 alan-agius4 added target: major This PR is targeted for the next major release action: merge The PR is ready for merge by the caretaker and removed target: patch This PR is targeted for the next patch release labels Aug 14, 2020
@alan-agius4 alan-agius4 merged commit a0e2f28 into angular:master Aug 14, 2020
@timdeschryver timdeschryver deleted the issue-13412 branch August 15, 2020 21:09
@timdeschryver
Copy link
Copy Markdown
Contributor Author

@alan-agius4 no need to say sorry.
Thanks for the help!

@angular-automatic-lock-bot
Copy link
Copy Markdown

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot Bot locked and limited conversation to collaborators Sep 15, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: merge The PR is ready for merge by the caretaker target: major This PR is targeted for the next major release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

e2e script is created in package.json when --createApplication=false

4 participants