test: fix canvas context property pane (#36356)
EE PR: https://github.com/appsmithorg/appsmith-ee/pull/5161 RCA: The property section related validations were not working Solution: - Enhanced verification of property pane section visibility using accessibility attributes. - Introduced new UI interaction properties for managing collapsible sections. /ok-to-test tags="@tag.IDE" <!-- This is an auto-generated comment: Cypress test results --> > [!TIP] > 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉 > Workflow run: <https://github.com/appsmithorg/appsmith/actions/runs/10919160204> > Commit: 3d5c864891f027d03e5d50ddb15a185f980d83aa > <a href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10919160204&attempt=1" target="_blank">Cypress dashboard</a>. > Tags: `@tag.IDE` > Spec: > <hr>Wed, 18 Sep 2024 09:42:19 UTC <!-- end of auto-generated comment: Cypress test results --> --------- Co-authored-by: “NandanAnantharamu” <“nandan@thinkify.io”>
This commit is contained in:
parent
e592eceaa8
commit
9f7e624b70
|
|
@ -195,12 +195,14 @@ function verifyPropertyPaneSectionState(propertySectionState) {
|
|||
for (const [sectionName, shouldSectionOpen] of Object.entries(
|
||||
propertySectionState,
|
||||
)) {
|
||||
cy.get("body").then(($body) => {
|
||||
const isSectionOpen =
|
||||
$body.find(`${propertySectionClass(sectionName)} .t--chevron-icon`)
|
||||
.length > 0;
|
||||
expect(isSectionOpen).to.equal(shouldSectionOpen);
|
||||
});
|
||||
cy.get(`${propertySectionClass(sectionName)}`)
|
||||
.siblings(_.locators._propertyCollapse)
|
||||
.find(_.locators._propertyCollapseBody)
|
||||
.invoke("attr", "aria-hidden")
|
||||
.then((isSectionOpen) => {
|
||||
const expectedValue = shouldSectionOpen ? "false" : "true";
|
||||
expect(isSectionOpen).to.equal(expectedValue);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -339,4 +339,6 @@ export class CommonLocators {
|
|||
_selectClearButton_testId = "selectbutton.btn.cancel";
|
||||
_selectClearButton_dataTestId = `[data-testid="${this._selectClearButton_testId}"]`;
|
||||
_saveDatasource = `[data-testid='t--store-as-datasource']`;
|
||||
_propertyCollapseBody = ".bp3-collapse-body";
|
||||
_propertyCollapse = ".bp3-collapse";
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user