Core: Work around loss of precision from parseFloat

Fixes #15100
This commit is contained in:
Richard Gibson
2014-06-07 14:22:49 -04:00
parent 6cb17c8ea4
commit b6e99eb43c
2 changed files with 4 additions and 2 deletions

View File

@@ -462,7 +462,7 @@ test("isFunction", function() {
});
test( "isNumeric", function() {
expect( 37 );
expect( 38 );
var t = jQuery.isNumeric,
Traditionalists = /** @constructor */ function(n) {
@@ -490,6 +490,7 @@ test( "isNumeric", function() {
ok( t("4.536"), "Positive floating point string");
ok( t(-2.6), "Negative floating point number");
ok( t(3.1415), "Positive floating point number");
ok( t(1.5999999999999999), "Very precise floating point number" );
ok( t(8e5), "Exponential notation");
ok( t("123e-2"), "Exponential notation string");
ok( t(answer), "Custom .toString returning number");