Offset: allow small differences in offset.top

Fixes gh-2590
(cherry picked from commit 9f9e204bba)
This commit is contained in:
Joelle Fleurantin
2015-10-18 12:45:41 -04:00
committed by Dave Methvin
parent d3a2fdce97
commit d047073d2b

View File

@@ -566,7 +566,9 @@ QUnit.test( "fractions (see #7730 and #7885)", function( assert ) {
result = div.offset();
assert.equal( result.top, expected.top, "Check top" );
// Support: Chrome 45-46+
// In recent Chrome these values differ a little.
assert.ok( Math.abs( result.top - expected.top ) < 0.25, "Check top within 0.25 of expected" );
assert.equal( result.left, expected.left, "Check left" );
div.remove();