mirror of
https://github.com/louislam/uptime-kuma.git
synced 2024-11-30 18:24:03 +00:00
fix(e2e): Ajust E2E test because there is no default condition anymore
This commit is contained in:
parent
90b9aeffb8
commit
72ecf7dbf2
1 changed files with 3 additions and 3 deletions
|
@ -28,16 +28,16 @@ test.describe("Monitor Form", () => {
|
||||||
await selectMonitorType(page);
|
await selectMonitorType(page);
|
||||||
|
|
||||||
await page.getByTestId("add-condition-button").click();
|
await page.getByTestId("add-condition-button").click();
|
||||||
expect(await page.getByTestId("condition").count()).toEqual(2); // 1 added by default + 1 explicitly added
|
expect(await page.getByTestId("condition").count()).toEqual(1); // 1 explicitly added
|
||||||
|
|
||||||
await page.getByTestId("add-group-button").click();
|
await page.getByTestId("add-group-button").click();
|
||||||
expect(await page.getByTestId("condition-group").count()).toEqual(1);
|
expect(await page.getByTestId("condition-group").count()).toEqual(1);
|
||||||
expect(await page.getByTestId("condition").count()).toEqual(3); // 2 solo conditions + 1 condition in group
|
expect(await page.getByTestId("condition").count()).toEqual(2); // 1 solo conditions + 1 condition in group
|
||||||
|
|
||||||
await screenshot(testInfo, page);
|
await screenshot(testInfo, page);
|
||||||
|
|
||||||
await page.getByTestId("remove-condition").first().click();
|
await page.getByTestId("remove-condition").first().click();
|
||||||
expect(await page.getByTestId("condition").count()).toEqual(2); // 1 solo condition + 1 condition in group
|
expect(await page.getByTestId("condition").count()).toEqual(1); // 0 solo condition + 1 condition in group
|
||||||
|
|
||||||
await page.getByTestId("remove-condition-group").first().click();
|
await page.getByTestId("remove-condition-group").first().click();
|
||||||
expect(await page.getByTestId("condition-group").count()).toEqual(0);
|
expect(await page.getByTestId("condition-group").count()).toEqual(0);
|
||||||
|
|
Loading…
Reference in a new issue