fix(frontend): preserve Pi auth asset guidance

This commit is contained in:
2026-08-14 19:14:53 +02:00
parent 99012f04c2
commit 225d13cd75
2 changed files with 18 additions and 1 deletions
+17
View File
@@ -299,6 +299,23 @@ test("shows a seven-step host-terminal workflow in scrollable platform tabs", as
expect(windows).toHaveTextContent('& (Resolve-Path "~\\bin\\thothctl-windows-amd64.exe") --installation (Resolve-Path "~\\thothii-installation.yaml") pi maintenance recover --yes');
});
test("keeps the required PI_AUTH_FILE guidance in one static text node", async () => {
const user = userEvent.setup();
renderManagement();
const tablist = await screen.findByRole("tablist", { name: "Pi host platform" });
await user.click(within(tablist).getByRole("tab", { name: "Linux" }));
const credentialStep = screen.getByRole("heading", { name: "Set the provider credential" }).closest("li");
const guidance = credentialStep?.querySelector("p");
expect(
Array.from(guidance?.childNodes ?? []).some(
(node) => node.nodeType === Node.TEXT_NODE
&& node.textContent?.includes("PI_AUTH_FILE is a setting in the installation environment file"),
),
).toBe(true);
});
test("reloads installation defaults when the panel is reopened", async () => {
let statusCalls = 0;
server.use(http.get("/api/pi-management/status", () => {