Skip to content

Commit cb3dc6e

Browse files
committed
fix(TreeviewMinimize): Treeview minimize new sidebar
1 parent a0c6ccc commit cb3dc6e

23 files changed

Lines changed: 10 additions & 16 deletions

File tree

tests/e2e/tests/model.test.js

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ test("object tree model components", async () => {
8888
.filter({ hasText: "test" })
8989
.locator("button:has(.mdi-magnify-expand)")
9090
.click();
91+
await window.mouse.move(0, 0);
9192
await window.waitForTimeout(afterActionWait);
9293

9394
const modelComponentsObjectTree = window.getByTestId("modelComponentsObjectTree");
@@ -106,23 +107,16 @@ test("object tree model components", async () => {
106107
await SurfacesRow.locator(".mdi-menu-right").first().click();
107108
await window.waitForTimeout(afterActionWait);
108109

109-
const surfaceIds = [
110-
"00000000-8afd-4969-8000-000092a43747",
111-
"00000000-1702-4d26-8000-000004d7ea39",
112-
"00000000-6732-4f29-8000-00002f66bc93",
113-
"00000000-cddf-4c1c-8000-00005ebbcaeb",
114-
"00000000-dc1c-420d-8000-000070dcfff5",
115-
"00000000-dcfe-400a-8000-0000a72c4f30",
116-
];
117-
118-
for (const surfaceId of surfaceIds) {
119-
console.log(`Unchecking surface: ${surfaceId}`);
120-
const surfaceRow = modelComponentsObjectTree
121-
.locator(".tree-row-wrapper")
122-
.filter({ hasText: surfaceId })
123-
.first();
110+
const surfaceLeafRows = modelComponentsObjectTree
111+
.locator(".tree-row-wrapper")
112+
.filter({ hasText: "00000000-" });
113+
114+
const surfaceCount = await surfaceLeafRows.count();
115+
console.log(`Found ${surfaceCount} surface leaf rows to uncheck`);
116+
for (let i = 0; i < surfaceCount; i += 1) {
117+
console.log(`Unchecking surface ${i + 1}/${surfaceCount}`);
124118
// oxlint-disable-next-line no-await-in-loop
125-
await surfaceRow.locator(".mdi-eye").first().click({ force: true });
119+
await surfaceLeafRows.nth(i).locator(".mdi-eye").first().click({ force: true });
126120
// oxlint-disable-next-line no-await-in-loop
127121
await window.waitForTimeout(afterActionWait);
128122
}
635 Bytes
Loading
602 Bytes
Loading
533 Bytes
Loading
545 Bytes
Loading
236 Bytes
Loading
-28 Bytes
Loading
916 Bytes
Loading
526 Bytes
Loading
-491 Bytes
Loading

0 commit comments

Comments
 (0)