chore: fix co2 battery e2e test

This commit is contained in:
Michael Geers 2025-07-28 14:32:09 +02:00
parent f4ac05d3d7
commit 2d2bc58e6e

View file

@ -26,10 +26,10 @@ test.describe("battery settings co2", async () => {
await page.getByTestId("energyflow").click();
await page.getByRole("button", { name: "grid charging active (≤ 150 g)" }).click();
await expectModalVisible(modal);
await modal.getByLabel("CO₂ limit").selectOption({ label: "≤ 40 g/kWh" });
await modal.getByLabel("CO₂ limit").selectOption({ label: "≤ 10 g/kWh" });
await modal.getByRole("button", { name: "Close" }).click();
await expectModalHidden(modal);
await expect(modal).not.toBeVisible();
await expect(page.getByRole("button", { name: "grid charging when ≤ 40 g" })).toBeVisible();
await expect(page.getByRole("button", { name: "grid charging when ≤ 10 g" })).toBeVisible();
});
});