* fix(ci): skip unrelated required checks cleanly Matrix jobs had to start no-op runners to preserve interpolated required-check names. Static named jobs let GitHub report genuine skipped conclusions while keeping those names stable. * fix(ci): gate changes to install patching script * fix(ci): route cross-package test contracts narrowly * fix(ci): keep routed contracts merge-blocking * fix(server): exclude nested test utilities from builds * fix(ci): cover app-owned native and browser domains * refactor(ci): align tests with runtime domains Own browser specs, desktop specs, and Electron-only app code by stable directories so PR routing does not depend on filename conventions. Keep desktop integration coverage inside the required desktop check. * fix(ci): keep routing and desktop suites isolated The routing regression must run before dependency installation, and desktop Vitest must not collect Playwright-owned specs. * fix(ci): isolate desktop e2e runtime * perf(test): isolate Playwright workers * perf(test): parallelize Playwright within specs * fix(test): keep Playwright file scheduling * fix(test): share dynamic Metro fixture * fix(test): preserve own-host restart fixtures * fix(ci): preserve routed contracts after rebase * Stabilize Playwright wheel-scroll assertions
89 lines
2.9 KiB
TypeScript
89 lines
2.9 KiB
TypeScript
import { test } from "../support/fixtures";
|
|
import { gotoAppShell } from "../support/helpers/app";
|
|
import { getE2EDaemonPort } from "../support/helpers/daemon-port";
|
|
import {
|
|
expectNewWorkspaceDraft,
|
|
expectNewWorkspaceProjectSelected,
|
|
fillNewWorkspaceDraft,
|
|
openGlobalNewWorkspaceComposer,
|
|
openNewWorkspaceComposer,
|
|
selectNewWorkspaceHost,
|
|
selectNewWorkspaceProject,
|
|
} from "../support/helpers/new-workspace";
|
|
import { seedWorkspace, type SeededWorkspace } from "../support/helpers/seed-client";
|
|
import { getServerId } from "../support/helpers/server-id";
|
|
import { seedSavedSettingsHosts } from "../support/helpers/settings";
|
|
import { waitForSidebarHydration } from "../support/helpers/workspace-ui";
|
|
|
|
const DRAFT = `Please investigate the workspace startup failure.
|
|
|
|
Trace the request from the app through the daemon, preserve the existing behavior, and explain the root cause before making changes.`;
|
|
|
|
test.describe("New workspace composer draft", () => {
|
|
test.describe.configure({ timeout: 240_000 });
|
|
|
|
test("keeps the draft when the project changes", async ({ page }) => {
|
|
const firstProject: SeededWorkspace = await seedWorkspace({
|
|
repoPrefix: "new-workspace-draft-project-a-",
|
|
});
|
|
const secondProject: SeededWorkspace = await seedWorkspace({
|
|
repoPrefix: "new-workspace-draft-project-b-",
|
|
});
|
|
|
|
try {
|
|
await gotoAppShell(page);
|
|
await waitForSidebarHydration(page);
|
|
await openNewWorkspaceComposer(page, {
|
|
projectKey: firstProject.projectKey,
|
|
projectDisplayName: firstProject.projectDisplayName,
|
|
});
|
|
await expectNewWorkspaceProjectSelected(page, firstProject.projectDisplayName);
|
|
|
|
await fillNewWorkspaceDraft(page, DRAFT);
|
|
|
|
await selectNewWorkspaceProject(page, {
|
|
projectKey: secondProject.projectKey,
|
|
projectDisplayName: secondProject.projectDisplayName,
|
|
});
|
|
|
|
await expectNewWorkspaceDraft(page, DRAFT);
|
|
} finally {
|
|
await secondProject.cleanup();
|
|
await firstProject.cleanup();
|
|
}
|
|
});
|
|
|
|
test("keeps the draft when the host changes", async ({ page }) => {
|
|
const project: SeededWorkspace = await seedWorkspace({
|
|
repoPrefix: "new-workspace-draft-host-",
|
|
});
|
|
const secondaryServerId = "new-workspace-draft-secondary-host";
|
|
|
|
try {
|
|
await seedSavedSettingsHosts(page, [
|
|
{
|
|
serverId: getServerId(),
|
|
label: "Primary host",
|
|
endpoint: `127.0.0.1:${getE2EDaemonPort()}`,
|
|
},
|
|
{
|
|
serverId: secondaryServerId,
|
|
label: "Secondary host",
|
|
endpoint: "127.0.0.1:9",
|
|
},
|
|
]);
|
|
|
|
await gotoAppShell(page);
|
|
await waitForSidebarHydration(page);
|
|
await openGlobalNewWorkspaceComposer(page);
|
|
|
|
await fillNewWorkspaceDraft(page, DRAFT);
|
|
await selectNewWorkspaceHost(page, "Secondary host");
|
|
|
|
await expectNewWorkspaceDraft(page, DRAFT);
|
|
} finally {
|
|
await project.cleanup();
|
|
}
|
|
});
|
|
});
|