Skip to content

Commit

Permalink
feat: support data-qa selector in selector playground (cypress-io#25475)
Browse files Browse the repository at this point in the history
  • Loading branch information
lmiller1990 authored Jan 20, 2023
1 parent 8b1d74f commit ad0b2a3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ const { $ } = window.Cypress.$Cypress
const SelectorPlayground = Cypress.SelectorPlayground

const SELECTOR_DEFAULTS = [
'data-cy', 'data-test', 'data-testid', 'id', 'class', 'tag', 'attributes', 'nth-child',
'data-cy', 'data-test', 'data-testid', 'data-qa', 'id', 'class', 'tag', 'attributes', 'nth-child',
]

describe('src/cypress/selector_playground', () => {
Expand Down
2 changes: 1 addition & 1 deletion packages/driver/src/cypress/selector_playground.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import uniqueSelector from '@cypress/unique-selector'
import $utils from './utils'
import $errUtils from './error_utils'

const SELECTOR_PRIORITIES = 'data-cy data-test data-testid id class tag attributes nth-child'.split(' ')
const SELECTOR_PRIORITIES = 'data-cy data-test data-testid data-qa id class tag attributes nth-child'.split(' ')

type Defaults = {
onElement: Cypress.SelectorPlaygroundDefaultsOptions['onElement'] | null
Expand Down

0 comments on commit ad0b2a3

Please sign in to comment.