Normalize vfs (#558)
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
import { test, testSkipIfWindows } from "./helpers/test_helper";
|
||||
import { test } from "./helpers/test_helper";
|
||||
import { expect } from "@playwright/test";
|
||||
import fs from "fs";
|
||||
import path from "path";
|
||||
|
||||
const MINIMAL_APP = "minimal-with-ai-rules";
|
||||
|
||||
testSkipIfWindows("problems auto-fix - enabled", async ({ po }) => {
|
||||
test("problems auto-fix - enabled", async ({ po }) => {
|
||||
await po.setUp();
|
||||
await po.importApp(MINIMAL_APP);
|
||||
await po.expectPreviewIframeIsVisible();
|
||||
@@ -18,41 +18,35 @@ testSkipIfWindows("problems auto-fix - enabled", async ({ po }) => {
|
||||
await po.snapshotMessages({ replaceDumpPath: true });
|
||||
});
|
||||
|
||||
testSkipIfWindows(
|
||||
"problems auto-fix - gives up after 2 attempts",
|
||||
async ({ po }) => {
|
||||
await po.setUp();
|
||||
await po.importApp(MINIMAL_APP);
|
||||
await po.expectPreviewIframeIsVisible();
|
||||
test("problems auto-fix - gives up after 2 attempts", async ({ po }) => {
|
||||
await po.setUp();
|
||||
await po.importApp(MINIMAL_APP);
|
||||
await po.expectPreviewIframeIsVisible();
|
||||
|
||||
await po.sendPrompt("tc=create-unfixable-ts-errors");
|
||||
await po.sendPrompt("tc=create-unfixable-ts-errors");
|
||||
|
||||
await po.snapshotServerDump("all-messages", { dumpIndex: -2 });
|
||||
await po.snapshotServerDump("all-messages", { dumpIndex: -1 });
|
||||
await po.snapshotServerDump("all-messages", { dumpIndex: -2 });
|
||||
await po.snapshotServerDump("all-messages", { dumpIndex: -1 });
|
||||
|
||||
await po.page.getByTestId("problem-summary").last().click();
|
||||
await expect(
|
||||
po.page.getByTestId("problem-summary").last(),
|
||||
).toMatchAriaSnapshot();
|
||||
await po.snapshotMessages({ replaceDumpPath: true });
|
||||
},
|
||||
);
|
||||
await po.page.getByTestId("problem-summary").last().click();
|
||||
await expect(
|
||||
po.page.getByTestId("problem-summary").last(),
|
||||
).toMatchAriaSnapshot();
|
||||
await po.snapshotMessages({ replaceDumpPath: true });
|
||||
});
|
||||
|
||||
testSkipIfWindows(
|
||||
"problems auto-fix - complex delete-rename-write",
|
||||
async ({ po }) => {
|
||||
await po.setUp();
|
||||
await po.importApp(MINIMAL_APP);
|
||||
await po.expectPreviewIframeIsVisible();
|
||||
test("problems auto-fix - complex delete-rename-write", async ({ po }) => {
|
||||
await po.setUp();
|
||||
await po.importApp(MINIMAL_APP);
|
||||
await po.expectPreviewIframeIsVisible();
|
||||
|
||||
await po.sendPrompt("tc=create-ts-errors-complex");
|
||||
await po.sendPrompt("tc=create-ts-errors-complex");
|
||||
|
||||
await po.snapshotServerDump("all-messages", { dumpIndex: -2 });
|
||||
await po.snapshotServerDump("all-messages", { dumpIndex: -1 });
|
||||
await po.snapshotServerDump("all-messages", { dumpIndex: -2 });
|
||||
await po.snapshotServerDump("all-messages", { dumpIndex: -1 });
|
||||
|
||||
await po.snapshotMessages({ replaceDumpPath: true });
|
||||
},
|
||||
);
|
||||
await po.snapshotMessages({ replaceDumpPath: true });
|
||||
});
|
||||
|
||||
test("problems auto-fix - disabled", async ({ po }) => {
|
||||
await po.setUp({ disableAutoFixProblems: true });
|
||||
|
||||
Reference in New Issue
Block a user