aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib
diff options
context:
space:
mode:
authorFelix Nagel <info@felixnagel.com>2017-08-26 13:08:14 +0200
committerFelix Nagel <info@felixnagel.com>2017-08-26 13:08:14 +0200
commit1b885ff76899fb70cce28371968d314ea74b7d7a (patch)
tree1a3a19be9d874f9daffd1238950c073ec086ffc2 /tests/lib
parent2b611bad90fa6f19e3bf02912c6cd5c08903c993 (diff)
parent74f8a0ac952f6f45f773312292baef1c26d81300 (diff)
downloadjquery-ui-datepicker.tar.gz
jquery-ui-datepicker.zip
Merge branch 'master' into datepickerdatepicker
# Conflicts: # ui/i18n/datepicker-pt.js
Diffstat (limited to 'tests/lib')
-rw-r--r--tests/lib/bootstrap.js6
-rw-r--r--tests/lib/qunit-assert-domequal.js8
2 files changed, 10 insertions, 4 deletions
diff --git a/tests/lib/bootstrap.js b/tests/lib/bootstrap.js
index e3d344cec..ffb273837 100644
--- a/tests/lib/bootstrap.js
+++ b/tests/lib/bootstrap.js
@@ -181,9 +181,9 @@ function migrateUrl() {
}
}
- // Load the jQuery 1.7 fixes, if necessary
- if ( parseFloat( parseUrl().jquery ) === 1.7 ) {
- modules.push( "ui/jquery-1-7" );
+ // Load the jQuery fixes, if necessary
+ if ( parseFloat( parseUrl().jquery ) < 3 ) {
+ modules.unshift( "ui/jquery-1-7" );
}
requireTests( modules, noBackCompat );
diff --git a/tests/lib/qunit-assert-domequal.js b/tests/lib/qunit-assert-domequal.js
index b22bd90b9..35695c4f1 100644
--- a/tests/lib/qunit-assert-domequal.js
+++ b/tests/lib/qunit-assert-domequal.js
@@ -59,6 +59,12 @@ domEqual.attributes = [
"title"
];
+function camelCase( string ) {
+ return string.replace( /-([\da-z])/gi, function( all, letter ) {
+ return letter.toUpperCase();
+ } );
+}
+
function getElementStyles( elem ) {
var styles = {};
var style = elem.ownerDocument.defaultView ?
@@ -71,7 +77,7 @@ function getElementStyles( elem ) {
while ( len-- ) {
key = style[ len ];
if ( typeof style[ key ] === "string" ) {
- styles[ $.camelCase( key ) ] = style[ key ];
+ styles[ camelCase( key ) ] = style[ key ];
}
}