Skip to content

Commit

Permalink
round values for the test to pass
Browse files Browse the repository at this point in the history
  • Loading branch information
MaggieCabrera committed Oct 16, 2024
1 parent d07b198 commit b88cd23
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions test/e2e/specs/site-editor/zoom-out.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,11 @@ test.describe( 'Zoom Out', () => {
const firstPatternRect = await firstPattern.boundingBox();

//Check that the toolbar is vertically aligned to the pattern and to the left
expect( toolbarRect.y ).toEqual( firstPatternRect.y );
expect( toolbarRect.x + toolbarRect.width ).toEqual(
firstPatternRect.x
expect( Math.round( toolbarRect.y ) ).toEqual(

Check failure on line 72 in test/e2e/specs/site-editor/zoom-out.spec.js

View workflow job for this annotation

GitHub Actions / Playwright - 6

[chromium] › site-editor/zoom-out.spec.js:48:2 › Zoom Out › When in zoom out

1) [chromium] › site-editor/zoom-out.spec.js:48:2 › Zoom Out › When in zoom out, a vertical toolbar appears for sections Error: expect(received).toEqual(expected) // deep equality Expected: 60 Received: 61 70 | 71 | //Check that the toolbar is vertically aligned to the pattern and to the left > 72 | expect( Math.round( toolbarRect.y ) ).toEqual( | ^ 73 | Math.round( firstPatternRect.y ) 74 | ); 75 | expect( at /home/runner/work/gutenberg/gutenberg/test/e2e/specs/site-editor/zoom-out.spec.js:72:41

Check failure on line 72 in test/e2e/specs/site-editor/zoom-out.spec.js

View workflow job for this annotation

GitHub Actions / Playwright - 6

[chromium] › site-editor/zoom-out.spec.js:48:2 › Zoom Out › When in zoom out

1) [chromium] › site-editor/zoom-out.spec.js:48:2 › Zoom Out › When in zoom out, a vertical toolbar appears for sections Retry #1 ─────────────────────────────────────────────────────────────────────────────────────── Error: expect(received).toEqual(expected) // deep equality Expected: 60 Received: 61 70 | 71 | //Check that the toolbar is vertically aligned to the pattern and to the left > 72 | expect( Math.round( toolbarRect.y ) ).toEqual( | ^ 73 | Math.round( firstPatternRect.y ) 74 | ); 75 | expect( at /home/runner/work/gutenberg/gutenberg/test/e2e/specs/site-editor/zoom-out.spec.js:72:41

Check failure on line 72 in test/e2e/specs/site-editor/zoom-out.spec.js

View workflow job for this annotation

GitHub Actions / Playwright - 6

[chromium] › site-editor/zoom-out.spec.js:48:2 › Zoom Out › When in zoom out

1) [chromium] › site-editor/zoom-out.spec.js:48:2 › Zoom Out › When in zoom out, a vertical toolbar appears for sections Retry #2 ─────────────────────────────────────────────────────────────────────────────────────── Error: expect(received).toEqual(expected) // deep equality Expected: 60 Received: 61 70 | 71 | //Check that the toolbar is vertically aligned to the pattern and to the left > 72 | expect( Math.round( toolbarRect.y ) ).toEqual( | ^ 73 | Math.round( firstPatternRect.y ) 74 | ); 75 | expect( at /home/runner/work/gutenberg/gutenberg/test/e2e/specs/site-editor/zoom-out.spec.js:72:41
Math.round( firstPatternRect.y )
);
expect(
Math.round( toolbarRect.x ) + Math.round( toolbarRect.width )
).toEqual( Math.round( firstPatternRect.x ) );
} );
} );

0 comments on commit b88cd23

Please sign in to comment.