Skip to content

test(devtools): fix and update flaky component-tree tests#67682

Open
hawkgs wants to merge 1 commit intoangular:mainfrom
hawkgs:devtools/fix-cmp-tree-tests
Open

test(devtools): fix and update flaky component-tree tests#67682
hawkgs wants to merge 1 commit intoangular:mainfrom
hawkgs:devtools/fix-cmp-tree-tests

Conversation

@hawkgs
Copy link
Member

@hawkgs hawkgs commented Mar 13, 2026

Due to the design of the ng.getComponent spy and a race condition where sometimes a <script> is added to the test DOM, the getRootElements tests used to fail sometimes because those <script>s were marked as roots which caused a distortion in the roots count checks. The commit addresses that and also adds an additional test for non-application root Angular components.

Due to the design of the `ng.getComponent` spy and a race condition where sometimes a `<script>` is added to the test DOM, the `getRootElements` tests used to fail sometimes because those `<script>`s were marked as roots which caused a distortion in the roots count checks. The commit addresses that and also adds an additional test for non-application root Angular components.
@ngbot ngbot bot added this to the Backlog milestone Mar 13, 2026
@hawkgs hawkgs added target: minor This PR is targeted for the next minor release and removed target: minor This PR is targeted for the next minor release labels Mar 13, 2026
@JeanMeche JeanMeche added the target: patch This PR is targeted for the next patch release label Mar 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: devtools target: patch This PR is targeted for the next patch release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants