refactor(tests): removing configureTestSuite()#15616
Merged
Merged
Conversation
added 10 commits
March 28, 2025 09:20
…-angular into tests-refactor
14 tasks
…into tests-refactor
Co-authored-by: Stamen Stoychev <sstoychev@infragistics.com> Co-authored-by: Teodosia Hristodorova <52423497+teodosiah@users.noreply.github.com>
chore(*)-update-readme-19.2
* fix(CSV): Skip group columns when exporting to CSV. * fix(PivotCSV): Fixed exporter when row dimensions exist.
…-angular into tests-refactor
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR refactors the test setups by removing legacy calls to configureTestSuite() and replacing them with beforeEach(waitForAsync(…)) to improve test isolation and reliability. It also introduces a temporary fix for test fixture destruction by hardcoding component IDs and updates Karma configuration by removing an obsolete CSS file reference.
Reviewed Changes
Copilot reviewed 173 out of 175 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| projects/igniteui-angular/src/lib/chips/chip.spec.ts | Replaces configureTestSuite with beforeEach and adds a fixed id assignment for fixture cleanup. |
| projects/igniteui-angular/src/lib/checkbox/checkbox.component.spec.ts | Updates test setup from configureTestSuite to beforeEach and adds a fixed id for fixture destruction. |
| projects/igniteui-angular/src/lib/carousel/carousel.component.spec.ts | Replaces deprecated configureTestSuite with beforeEach for TestBed configuration. |
| projects/igniteui-angular/src/lib/card/card.spec.ts | Switches test initialization to beforeEach without using configureTestSuite. |
| projects/igniteui-angular/src/lib/calendar/month-picker/month-picker.component.spec.ts | Uses beforeEach instead of configureTestSuite. |
| projects/igniteui-angular/src/lib/calendar/days-view/days-view.component.spec.ts | Replaces beforeAll with beforeEach for asynchronous test setup. |
| projects/igniteui-angular/src/lib/calendar/calendar.component.spec.ts | Updates test configuration pattern from beforeAll to beforeEach. |
| projects/igniteui-angular/src/lib/calendar/calendar-multi-view.component.spec.ts | Uses beforeEach rather than configureTestSuite for TestBed initialization. |
| projects/igniteui-angular/src/lib/buttonGroup/buttongroup.component.spec.ts | Switches test setup to beforeEach from the legacy configureTestSuite. |
| projects/igniteui-angular/src/lib/banner/banner.component.spec.ts | Adopts beforeEach for asynchronous test initialization and removes configureTestSuite. |
| projects/igniteui-angular/src/lib/badge/badge.component.spec.ts | Replaces configureTestSuite with beforeEach for TestBed configuration. |
| projects/igniteui-angular/src/lib/avatar/avatar.component.spec.ts | Removes legacy test configuration helper in favor of beforeEach. |
| projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.spec.ts | Updates test setup from configureTestSuite to beforeEach. |
| projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.spec.ts | Replaces deprecated initialization pattern with beforeEach. |
| projects/igniteui-angular/src/lib/action-strip/action-strip.component.spec.ts | Modifies test configuration to utilize beforeEach instead of configureTestSuite. |
| projects/igniteui-angular/src/lib/accordion/accordion.component.spec.ts | Moves test initialization from beforeAll to beforeEach and removes configureTestSuite. |
| projects/igniteui-angular/karma.watch.conf.js | Removes obsolete global CSS file reference to streamline test execution. |
| projects/igniteui-angular/karma.conf.js | Removes the igniteui-angular.css reference to update the Karma configuration. |
Files not reviewed (2)
- angular.json: Language not supported
- package.json: Language not supported
Comments suppressed due to low confidence (2)
projects/igniteui-angular/karma.watch.conf.js:11
- Removal of the global CSS file reference may affect component styling in tests; please verify that the required global styles are loaded through an alternative configuration.
{ pattern: '../../dist/igniteui-angular/styles/igniteui-angular.css', watched: false }
projects/igniteui-angular/karma.conf.js:12
- Ensure that removing the igniteui-angular.css reference does not inadvertently omit essential global styles needed for consistent styling in tests.
{ pattern: '../../dist/igniteui-angular/styles/igniteui-angular.css', watched: false }
damyanpetev
approved these changes
Apr 29, 2025
This file contains hidden or 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
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.
Closes #
Additional information (check all that apply):
Checklist:
feature/README.MDupdates for the feature docsREADME.MDCHANGELOG.MDupdates for newly added functionalityng updatemigrations for the breaking changes (migrations guidelines)