mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/MultimediaViewer
synced 2024-09-25 11:17:54 +00:00
Smoke test for MultiLightbox class.
Change-Id: Iab8a80d842d4252a68bca2a4de92acccd835c978
This commit is contained in:
parent
8695964ea4
commit
83aa9c6a6b
|
@ -120,6 +120,7 @@ class MultimediaViewerHooks {
|
|||
'tests/qunit/ext.multimediaViewer.test.js',
|
||||
'tests/qunit/lightboximage.test.js',
|
||||
'tests/qunit/lightboxinterface.test.js',
|
||||
'tests/qunit/multilightbox.test.js',
|
||||
),
|
||||
'dependencies' => array(
|
||||
'ext.multimediaViewer',
|
||||
|
|
11
tests/qunit/multilightbox.test.js
Normal file
11
tests/qunit/multilightbox.test.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
( function () {
|
||||
QUnit.module( 'ext.multimediaViewer.multiLightbox', QUnit.newMwEnvironment() );
|
||||
|
||||
QUnit.test( 'Smoke test', 1, function ( assert ) {
|
||||
var lightboxImage = new window.LightboxImage( 'http://en.wikipedia.org/w/skins/vector/images/search-ltr.png' ),
|
||||
multiLightbox = new window.MultiLightbox( [lightboxImage] );
|
||||
|
||||
assert.strictEqual( multiLightbox.currentIndex, 0, 'currentIndex initialized correctly.' );
|
||||
} );
|
||||
|
||||
}( mediaWiki, jQuery ) );
|
Loading…
Reference in a new issue