Note abut Selector Priority#6408
Open
emilyrohrbough wants to merge 2 commits into
Open
Conversation
cypress-documentation
|
||||||||||||||||||||||||||||||||||||||||
| Project |
cypress-documentation
|
| Branch Review |
selector-priority
|
| Run status |
|
| Run duration | 06m 21s |
| Commit |
|
| Committer | Emily Wisniewski |
| View all properties for this run ↗︎ | |
| Test results | |
|---|---|
|
|
0
|
|
|
0
|
|
|
0
|
|
|
0
|
|
|
320
|
| View all changes introduced in this branch ↗︎ | |
UI Coverage
10.34%
|
|
|---|---|
|
|
2715
|
|
|
3
|
Accessibility
96.89%
|
|
|---|---|
|
|
1 critical
3 serious
4 moderate
1 minor
|
|
|
35
|
|
|
||
| ## Where to configure | ||
|
|
||
| Call `Cypress.ElementSelector.defaults({ ... })` once in your [support file](/app/references/configuration). You want this to load before your specs and do **not** want to set this inside `describe`, `it`, `before`, `beforeEach`, or similar test hooks. |
Member
There was a problem hiding this comment.
why not set it in hooks or code?
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.
Note
Low Risk
Documentation-only updates that clarify where
Cypress.ElementSelector.defaults()can be configured and how AI skills choose selectors; no runtime or API behavior changes.Overview
Adds a "Where to configure" section to
Cypress.ElementSelectordocs, clarifying thatCypress.ElementSelector.defaults({ ... })should be called once from the support/spec context (not Node config) and loaded before specs.Updates the
cypress-authorAI Skills documentation to state it attempts to follow the project’s configuredCypress.ElementSelectorselector priority rather than a fixeddata-*hierarchy.Reviewed by Cursor Bugbot for commit b64207b. Bugbot is set up for automated code reviews on this repo. Configure here.