Merge "New hook for readonly editpages"
[lhc/web/wiklou.git] / tests / qunit / suites / resources / jquery / jquery.getAttrs.test.js
index 6eef1ab..0b7e87e 100644 (file)
@@ -1,11 +1,13 @@
-QUnit.module( 'jquery.getAttrs', QUnit.newMwEnvironment() );
+( function ( $ ) {
+       QUnit.module( 'jquery.getAttrs', QUnit.newMwEnvironment() );
 
-QUnit.test( 'Check', 1, function ( assert ) {
-       var     attrs = {
-                       foo: 'bar',
-                       'class': 'lorem'
-               },
-               $el = jQuery( '<div>', attrs );
+       QUnit.test( 'Check', 1, function ( assert ) {
+               var attrs = {
+                               foo: 'bar',
+                               'class': 'lorem'
+                       },
+                       $el = $( '<div>' ).attr( attrs );
 
-       assert.deepEqual( $el.getAttrs(), attrs, 'getAttrs() return object should match the attributes set, no more, no less' );
-} );
+               assert.deepEqual( $el.getAttrs(), attrs, 'getAttrs() return object should match the attributes set, no more, no less' );
+       } );
+}( jQuery ) );