Skip to content

Commit 9f9e204

Browse files
Queeniebeedmethvin
authored andcommitted
Offset: allow small differences in offset.top
Fixes gh-2590
1 parent c577928 commit 9f9e204

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

test/unit/offset.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -548,7 +548,9 @@ QUnit.test( "fractions (see #7730 and #7885)", function( assert ) {
548548

549549
result = div.offset();
550550

551-
assert.equal( result.top, expected.top, "Check top" );
551+
// Support: Chrome 45-46+
552+
// In recent Chrome these values differ a little.
553+
assert.ok( Math.abs( result.top - expected.top ) < 0.25, "Check top within 0.25 of expected" );
552554
assert.equal( result.left, expected.left, "Check left" );
553555

554556
div.remove();

0 commit comments

Comments
 (0)