mirror of
https://github.com/penpot/penpot.git
synced 2026-03-09 03:35:40 +00:00
Merge pull request #4844 from penpot/eva-fix-visual-test
🐛 Fix workspace visual test for assets modal
This commit is contained in:
@@ -0,0 +1 @@
|
||||
{}
|
||||
@@ -202,6 +202,7 @@ export class WorkspacePage extends BaseWebSocketPage {
|
||||
|
||||
async openLibrariesModal(clickOptions = {}) {
|
||||
await this.sidebar.getByText("Libraries").click(clickOptions);
|
||||
await expect(this.librariesModal).toBeVisible();
|
||||
}
|
||||
|
||||
async clickLibrary(name, clickOptions = {}) {
|
||||
|
||||
@@ -83,14 +83,22 @@ test.describe("Assets tab", () => {
|
||||
"workspace/get-team-shared-libraries-non-empty.json",
|
||||
);
|
||||
|
||||
await workspace.mockRPC(
|
||||
"push-audit-events",
|
||||
"workspace/audit-event-empty.json",
|
||||
);
|
||||
|
||||
await workspace.goToWorkspace();
|
||||
await workspace.clickAssets();
|
||||
await workspace.openLibrariesModal();
|
||||
|
||||
await expect(workspace.page).toHaveScreenshot();
|
||||
|
||||
await workspace.clickLibrary("Testing library 1");
|
||||
|
||||
await expect(
|
||||
workspace.librariesModal.getByText(
|
||||
"There are no Shared Libraries available",
|
||||
),
|
||||
).toBeVisible();
|
||||
await expect(workspace.page).toHaveScreenshot();
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user