-
Notifications
You must be signed in to change notification settings - Fork 261
WS-MAINTENANCE: Refactors unused cypress suites. #13557
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
base: latest
Are you sure you want to change the base?
Conversation
|
|
||
| describe('Header Tests', () => { | ||
| const serviceName = config[service]?.name || service; | ||
| const serviceName = service; |
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.
Does this need aliased? Can we just use service throughout the is test?
amoore108
left a comment
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 this, looks great 👍
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.
Pull request overview
This PR removes redundant Cypress helper functions and configuration files to clean up the test suite. The refactoring eliminates the intermediate service configuration lookup that was mapping service identifiers to names, simplifying the codebase by using service identifiers directly.
Key changes:
- Removed the entire
settings.tsconfiguration file containing service-to-name mappings - Removed the
services.tshelper that filtered services based on environment variables - Updated test files to use service identifiers directly instead of looking up service names
Reviewed changes
Copilot reviewed 22 out of 22 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
testsForCanonicalOnly.ts |
Simplified to use service identifier directly instead of looking up service name from config |
testsForAMPOnly.ts |
Removed service config lookup, now passes service identifier directly to cy.getToggles |
settings.ts |
Deleted entire file containing service configuration mappings |
services.ts |
Deleted helper file that provided filtered service configurations |
testsForAllCanonicalPages.ts |
Removed config lookup for serviceName, uses service identifier directly |
testsForAllAMPPages.ts |
Simplified conditional by removing config lookup layer |
atiAnalytics/assertions/*.ts (11 files) |
Cleaned up import paths to use relative imports from index file instead of deeply nested absolute paths |
atiAnalytics/assertions/index.ts |
New file consolidating assertion functions previously imported from absolute paths |
crossPlatformAssertion.ts |
Removed service config lookups, uses service identifier directly throughout |
MeriemMechri
left a comment
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.
LGTM - thank you!
Resolves JIRA: No-Jira
Summary
Removes redundant cypress helper functions.
Code changes
Developer Checklist
Testing
Ready-For-Test, Local)Ready-For-Test, Test)Ready-For-Test, Preview)Ready-For-Test, Live)Additional Testing Steps
Useful Links