build: Enable jscs rules 'requireSpacesInside*Brackets' and make pass
[lhc/web/wiklou.git] / resources / src / jquery / jquery.qunit.completenessTest.js
index 8d38401..e34592c 100644 (file)
@@ -17,8 +17,8 @@
 
        var util,
                hasOwn = Object.prototype.hasOwnProperty,
-               log = (window.console && window.console.log)
-                       ? function () { return window.console.log.apply(window.console, arguments); }
+               log = ( window.console && window.console.log )
+                       ? function () { return window.console.log.apply( window.console, arguments ); }
                        : function () {};
 
        // Simplified version of a few jQuery methods, except that they don't
@@ -91,7 +91,7 @@
                        // Restore warnings
                        mw.log.warn = warn;
                        warn = undefined;
-               });
+               } );
 
                QUnit.done( function () {
                        that.populateMissingTests();
                                        var elItem = document.createElement( 'li' );
                                        elItem.textContent = key;
                                        elList.appendChild( elItem );
-                               });
+                               } );
 
                                elFoot = document.createElement( 'p' );
                                elFoot.innerHTML = '<em>&mdash; CompletenessTest</em>';
                                elOutputWrapper.appendChild( elContainer );
 
                                util.each( style, function ( key, value ) {
-                                       elOutputWrapper.style[key] = value;
-                               });
+                                       elOutputWrapper.style[ key ] = value;
+                               } );
                                return elOutputWrapper;
                        }
 
                        if ( toolbar ) {
                                toolbar.insertBefore( testResults, toolbar.firstChild );
                        }
-               });
+               } );
 
                return this;
        }
 
                        if ( currName ) {
                                currPathArray.push( currName );
-                               currVal = currObj[currName];
+                               currVal = currObj[ currName ];
                        } else {
                                currName = '(root)';
                                currVal = currObj;
                        var ct = this;
                        util.each( ct.injectionTracker, function ( key ) {
                                ct.hasTest( key );
-                       });
+                       } );
                },
 
                /**
                 */
                hasTest: function ( fnName ) {
                        if ( !( fnName in this.methodCallTracker ) ) {
-                               this.missingTests[fnName] = true;
+                               this.missingTests[ fnName ] = true;
                                return false;
                        }
                        return true;
                        // Make the spy inherit from the original so that its static methods are also
                        // visible in the spy (e.g. when we inject a check into mw.log, mw.log.warn
                        // must remain accessible).
+                       // XXX: https://github.com/jshint/jshint/issues/2656
+                       /*jshint ignore:start */
                        /*jshint proto:true */
                        spy.__proto__ = val;
+                       /*jshint ignore:end */
 
                        // Objects are by reference, members (unless objects) are not.
                        obj[ key ] = spy;