Skip to content

Commit

Permalink
Merge pull request #6279 from Sage/batch-selection-flaky
Browse files Browse the repository at this point in the history
test(batch-selection): fix issue with flaky test
  • Loading branch information
DipperTheDan authored Aug 31, 2023
2 parents 31f8c14 + 844503a commit c1d9c37
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions src/components/batch-selection/batch-selection.pw.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,18 +38,16 @@ test.describe("check BatchSelection component properties", () => {

test("should check hidden BatchSelection", async ({ mount, page }) => {
await mount(<BatchSelectionComponent hidden />);
const batchSelection = batchSelectionComponent(page);
await expect(batchSelection.getAttribute("hidden")).not.toBeNull();

await expect(batchSelectionComponent(page).getAttribute("hidden"))
.toBeTruthy;

await expect(batchSelectionComponent(page)).toHaveCSS("opacity", "0");
await expect(batchSelection).toHaveCSS("opacity", "0");
});

test("should check disabled BatchSelection", async ({ mount, page }) => {
await mount(<BatchSelectionComponent disabled />);

await expect(batchSelectionComponent(page).getAttribute("disabled"))
.toBeTruthy;
const batchSelection = batchSelectionComponent(page);
await expect(batchSelection.getAttribute("disabled")).not.toBeNull();
});

([
Expand Down

0 comments on commit c1d9c37

Please sign in to comment.