saleor-dashboard/cypress/elements/shared/sharedElements.js
Karolina Rakoczy f68410b7cb
Saleor 3711 tests for categories and collections (#1204)
* tests for collections

* all tests for categories
2021-07-15 14:17:56 +03:00

19 lines
666 B
JavaScript

export const SHARED_ELEMENTS = {
header: "[data-test-id='page-header']",
progressBar: '[role="progressbar"]',
circularProgress: '[class*="CircularProgress-circle"]',
skeleton: '[data-test-id="skeleton"]',
table: 'table[class*="Table"]',
tableRow: '[data-test="id"]',
confirmationMsg: "[data-test='notification-success']",
searchInput: '[data-test-id="searchInput"]',
selectOption: '[data-test="selectFieldOption"]',
richTextEditor: {
empty: '[class*="codex-editor--empty"]'
}
};
export const selectorWithDataValue = value => `[data-value="${value}"]`;
export const getElementByDataTestId = dataTestId =>
`[data-test-id=${dataTestId}]`;