-( function ( mw, $ ) {
+( function () {
// Simulate square element with 20px long edges placed at (20, 20) on the page
var
}
} ) );
- QUnit.test( 'isElementInViewport', 6, function ( assert ) {
+ QUnit.test( 'isElementInViewport', function ( assert ) {
var viewport = $.extend( {}, DEFAULT_VIEWPORT );
assert.ok( mw.viewport.isElementInViewport( this.el, viewport ),
'It should return true when the element is fully enclosed in the viewport' );
'It should default to the window object if no viewport is given' );
} );
- QUnit.test( 'isElementInViewport with scrolled page', 1, function ( assert ) {
+ QUnit.test( 'isElementInViewport with scrolled page', function ( assert ) {
var viewport = {
top: 2000,
left: 0,
window.scrollTo( 0, 0 );
} );
- QUnit.test( 'isElementCloseToViewport', 3, function ( assert ) {
+ QUnit.test( 'isElementCloseToViewport', function ( assert ) {
var
viewport = {
top: 90,
'It should default to a threshold of 50px and the window\'s viewport' );
} );
-}( mediaWiki, jQuery ) );
+}() );