1
0
mirror of https://github.com/webslides/WebSlides.git synced 2025-08-18 02:41:37 +02:00

Fixing zoom test

This commit is contained in:
Luis
2017-06-21 17:26:51 +02:00
parent 5b45de0b79
commit 63ac064a25

View File

@@ -15,7 +15,8 @@ const simulateKeyEvent = (el, code) => {
beforeAll(() => {
const slides = '12345'.replace(/(\d)/g,
'<div id="section-$1" class="slide"><div>Slide $1</div></div>');
'<div id="section-$1" class="slide"><div>Slide $1</div></div>')
.replace('section-1" class="', 'section-1" class="current ');
document.body.innerHTML = `<div id="webslides">${slides}</div>`;
});
@@ -50,7 +51,7 @@ test('Zoom utility', () => {
expect(zws.style.display).toBe('');
// Wait until next execution
jest.runTimersToTime(401);
jest.runTimersToTime(500);
expect(disable.mock.calls.length).toBe(1);
expect(enable.mock.calls.length).toBe(0);
expect(goto.mock.calls.length).toBe(0);