saleor-dashboard/cypress/support/pages/configurationPage.js
wojteknowacki bf532939e2
Test navigation refactor (#3294)
* naviagtion aka permissions refactor
2023-03-09 09:18:07 +01:00

12 lines
445 B
JavaScript

import { CONFIGURATION_SELECTORS } from "../../elements";
export function expectConfigurationAvailableSectionsNumber(sectionsNumber) {
cy.get(CONFIGURATION_SELECTORS.configurationMenu)
.find("[data-test-id*=subsection]")
.should("have.length", sectionsNumber);
}
export function expectConfigurationSectionsToBeVisible(...sections) {
sections.forEach(selector => {
cy.get(selector).scrollIntoView().should("be.visible");
});
}