Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jgerigmeyer committed Nov 19, 2024
1 parent ec1c938 commit 6c59c15
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/e2e/polyfill.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ test('applies polyfill for `anchor()`', async ({ page }) => {

await applyPolyfill(page);

await expect(target).toHaveCSS('top', `${parentHeight}px`);
await expectWithinOne(target, 'top', parentHeight);
await expectWithinOne(target, 'right', expected);
});

Expand All @@ -88,7 +88,7 @@ test('applies polyfill from inline styles', async ({ page }) => {

await applyPolyfill(page);

await expect(targetInLine).toHaveCSS('top', `${parentHeight}px`);
await expectWithinOne(targetInLine, 'top', parentHeight);
await expectWithinOne(targetInLine, 'right', expected);
});

Expand All @@ -99,7 +99,7 @@ test('updates when sizes change', async ({ page }) => {
const parentHeight = await getParentHeight(page, targetSelector);
await applyPolyfill(page);

await expect(target).toHaveCSS('top', `${parentHeight}px`);
await expectWithinOne(target, 'top', parentHeight);
await expectWithinOne(target, 'right', parentWidth - width);

await page
Expand Down

0 comments on commit 6c59c15

Please sign in to comment.