-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: handle getStylesConfig returning a Promise in Angular 16 #26559
Merged
jordanpowell88
merged 1 commit into
cypress-io:jordanpowell88/angular-16-support
from
leosvelperez:feat/angular-16-webpack-styles-config
Apr 21, 2023
Merged
feat: handle getStylesConfig returning a Promise in Angular 16 #26559
jordanpowell88
merged 1 commit into
cypress-io:jordanpowell88/angular-16-support
from
leosvelperez:feat/angular-16-webpack-styles-config
Apr 21, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 flaky tests on run #45722 ↗︎
Details:
commands/net_stubbing.cy.ts • 1 flaky test • 5x-driver-firefox
create-from-component.cy.ts • 1 flaky test • app-e2e
specs_list_latest_runs.cy.ts • 1 flaky test • app-e2e
cypress/cypress.cy.js • 3 flaky tests • 5x-driver-firefox
cypress-origin-communicator.cy.ts • 1 flaky test • app-e2e
The first 5 flaky specs are shown, see all 15 specs in Cypress Cloud. This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. |
jordanpowell88
changed the base branch from
develop
to
jordanpowell88/angular-16-support
April 21, 2023 12:13
jordanpowell88
force-pushed
the
jordanpowell88/angular-16-support
branch
from
April 21, 2023 12:17
baaf717
to
598e429
Compare
jordanpowell88
approved these changes
Apr 21, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR @leosvelperez !
jordanpowell88
added a commit
that referenced
this pull request
Apr 24, 2023
* feat(angular): add support for Angular 16 * chore: update angular 16 pre-release version * feat: handle getStylesConfig returning a Promise in Angular 16 (#26559) * chore: remove next from deps to prepare for release * remove .only, add angular-16 to webpack-dev-server e2e tests --------- Co-authored-by: Leosvel Pérez Espinosa <leosvel.perez.espinosa@gmail.com> Co-authored-by: astone123 <adams@cypress.io>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Additional details
In the upcoming Angular 16, the
getStylesConfig
function returns aPromise
(angular/angular-cli@758b069#diff-b14bb6b4458b0b51ba8711c389cf6c73b0837d0cc8e09df93899d2db888e6ad6R37). The Angular handler uses that function and it doesn't expect it to return aPromise
. Therefore, it fails with Angular 16.The solution just wraps the call to
getStylesConfig
to always handle aPromise
regardless of the Angular version. That way we keep compatibility with older versions and support the new version.Steps to test
I wasn't sure if we wanted to add a fixture with Angular 16 RC version. I can do that if needed. The tests for the existing versions should still pass and would cover that this change doesn't break the compatibility with older versions.
How has the user experience changed?
PR Tasks
cypress-documentation
?type definitions
?