/
githubmirror
/
fullPage.js
Обзор
Документация
Войти
/
githubmirror
/
fullPage.js
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
tests/unit/loopBottom.js
19 строк
768 B
Alvaro Trigo López
Bunch of unit tests
08 май 2018, 16:54
08 май 2018, 16:54
a5b57ad
Код
Авторство
О чём код?
QUnit.test('Testing loopBottom:true', function(assert) { var id = '#fullpage-last-section-active'; var FP = initFullpageNew(id, {loopBottom: true}); assert.equal($(id).find(SECTION_ACTIVE_SEL).index(), 3, 'We expect section 4 to be active'); FP.moveSectionDown(); assert.equal($(id).find(SECTION_ACTIVE_SEL).index(), 0, 'We expect section 1 to be active'); }); QUnit.test('Testing loopBottom:false', function(assert) { var id = '#fullpage-last-section-active'; var FP = initFullpageNew(id, {loopBottom: false}); assert.equal($(id).find(SECTION_ACTIVE_SEL).index(), 3, 'We expect section 4 to be active'); FP.moveSectionDown(); assert.equal($(id).find(SECTION_ACTIVE_SEL).index(), 3, 'We expect section 1 to be active'); });