feat(card): add test harnesses and end-to-end tests#97
Conversation
|
@copilot Similar to Tabs, create card.po.ts (Page Object) for Card. Add an end-to-end test for every Card component story (Storybook) similar to Tabs. Use the component test harnesses and expand them as needed. |
I've successfully implemented comprehensive card page objects and end-to-end tests following the tabs pattern: Created:
Results:
Commit: 4fe8fd1 Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
|
@copilot Temporarily enable video recording in the Cypress CI config, run e2e tests and upload the Card video files to this PR. |
I've successfully enabled video recording, ran the e2e tests, and uploaded the Card test videos: Generated Videos:
Location: Cypress CI config reverted to Commit: b09b16c Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
b09b16c to
c414fb2
Compare
|
@copilot I rebased this branch after adding stricter lint rules. Make sure to resolve all linting and formatting issues. |
I've resolved all linting and formatting issues after the stricter rules were applied: Linting Fixes:
Results:
Commit: c642e2a Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
c642e2a to
4bcd91e
Compare
4bcd91e to
7bc4aa0
Compare
24f1aad to
d510c3d
Compare
|
@copilot A Testing chapter has been added to |
I've verified that all changes in this PR fully comply with the new Testing chapter requirements in ✅ Angular CDK-based component test harnesses:
✅ Unit tests using harnesses:
✅ E2E tests per Foundation documentation sections:
✅ Page Object pattern:
Results: 21/21 unit tests + 24/24 e2e tests passing, all linting clean. |
984de10 to
613aae9
Compare
…tests and test utilities
Add complete test harnesses for Card, CardSection, and CardDivider components with comprehensive tests Co-authored-by: LayZeeDK <6364586+LayZeeDK@users.noreply.github.com>
2b31239 to
8b906b8
Compare
8b906b8 to
fe66a0f
Compare
fe66a0f to
f538d35
Compare
Create comprehensive e2e test coverage for all card stories using harnesses and page object pattern Co-authored-by: LayZeeDK <6364586+LayZeeDK@users.noreply.github.com>
f538d35 to
f0f565d
Compare
Card component test harnesses and end-to-end testing completed successfully with video demonstrations, all linting/formatting issues resolved, and full compliance with AGENTS.md Testing requirements:
Implementation Summary
Test Harnesses
FasCardHarness- Main harness for<fas-card>with methods to locate sections/dividersFasCardSectionHarness- Harness for<fas-card-section>componentsFasCardDividerHarness- Harness for<fas-card-divider>componentsngx-foundation-sites/testingalongside existing tab harnessesPage Objects & E2E Tests
card.po.ts- Main page object with navigation utilitiesbasics.po.ts- Page object for basic card storyimages.po.ts- Page object for card with images storysizing.po.ts- Page object for card sizing/grid storycard-divider.po.ts- Page object for card divider storyE2E Test Coverage
basics.cy.ts- Tests for basic card functionality (4 tests)images.cy.ts- Tests for cards with images (3 tests)sizing.cy.ts- Tests for card sizing/grid layout (4 tests)card-divider.cy.ts- Tests for cards with dividers (4 tests)Video Demonstrations
card-test-videos/- Directory containing MP4 recordings of all card e2e testsCode Quality
AGENTS.md Testing Requirements Compliance
ComponentHarnesscard.spec.tscontains comprehensive tests using the harnesses to validate component functionalityTest Results
The implementation follows the exact same pattern as the existing Tabs harnesses and e2e tests, ensuring consistency and maintainability. All card component stories now have comprehensive test coverage using the component test harnesses, with video proof of functionality, full compliance with the project's strict code quality standards, and adherence to all AGENTS.md Testing chapter requirements.
basics.cy.ts.mp4
card-divider.cy.ts.mp4
images.cy.ts.mp4
sizing.cy.ts.mp4
ngx-foundation-sites/testingas is the case for the Tabs component test harnesses. Cover Card with tests using the component test harnesses similar to Tabs.Fixes #82
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.