diff --git a/test/test-multiple-instances-es5.html b/test/test-multiple-instances-es5.html index b80fe4482cb27e0490fe11b75c83f5be80ed381a..b08c94907daa8e15d24cc54645655de4fe792599 100644 --- a/test/test-multiple-instances-es5.html +++ b/test/test-multiple-instances-es5.html @@ -37,13 +37,15 @@ </div> <script src="../dist/reveal.es5.js"></script> + <script src="../dist/plugin/zoom.js"></script> <script> QUnit.module( 'Multiple reveal.js instances' ); let r1 = new Reveal( document.querySelector( '.deck1 .reveal' ), { embedded: true, - keyboard: true + keyboard: true, + plugins: [RevealZoom] } ); r1.initialize(); @@ -70,6 +72,13 @@ }); + QUnit.test( 'Can register plugins independently', function( assert ) { + + assert.ok( r1.hasPlugin( 'zoom' ) ); + assert.notOk( r2.hasPlugin( 'zoom' ) ); + + }); + </script> </body> diff --git a/test/test-multiple-instances.html b/test/test-multiple-instances.html index 50fe8ccf40de113ff2042314030d34f63cc1f829..92f85dfdb87461e0d9264f764b924eea2485430b 100644 --- a/test/test-multiple-instances.html +++ b/test/test-multiple-instances.html @@ -39,12 +39,14 @@ <script type="module"> import Reveal from '../dist/reveal.js'; + import Zoom from '../plugin/zoom/zoom.js'; QUnit.module( 'Multiple reveal.js instances' ); let r1 = new Reveal( document.querySelector( '.deck1 .reveal' ), { embedded: true, - keyboard: true + keyboard: true, + plugins: [Zoom] } ); r1.initialize(); @@ -71,6 +73,13 @@ }); + QUnit.test( 'Can register plugins independently', function( assert ) { + + assert.ok( r1.hasPlugin( 'zoom' ) ); + assert.notOk( r2.hasPlugin( 'zoom' ) ); + + }); + </script> <script> QUnit.test( 'Reveal does not leak to window', function( assert ) {