aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/test.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/test.js b/test/test.js
index 93a3d61..30b5c75 100644
--- a/test/test.js
+++ b/test/test.js
@@ -109,6 +109,14 @@ Reveal.addEventListener( 'ready', function() {
strictEqual( Reveal.getSlide( 100 ), undefined, 'returns undefined when slide can\'t be found' );
});
+ test( 'Reveal.getSlideBackground', function() {
+ var firstBackground = document.querySelector( '.reveal .backgrounds>.slide-background:first-child' );
+
+ equal( Reveal.getSlideBackground( 0 ), firstBackground, 'gets correct first background' );
+
+ strictEqual( Reveal.getSlideBackground( 100 ), undefined, 'returns undefined when background can\'t be found' );
+ });
+
test( 'Reveal.getPreviousSlide/getCurrentSlide', function() {
Reveal.slide( 0, 0 );
Reveal.slide( 1, 0 );