X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=client%2Fe2e%2Fsrc%2Fsuites-local%2Fplugins.e2e-spec.ts;h=363c7f8361fde644f0a8e798c57c3d92c4a8850e;hb=5b94394a1a6d471f897d14ac62fe7bec5f9a74c2;hp=55f020c448f14ce8bcdd7a2bafc80dd95434dfeb;hpb=cc4bf76c13e38e9065d49161b6e0485657424577;p=github%2FChocobozzz%2FPeerTube.git diff --git a/client/e2e/src/suites-local/plugins.e2e-spec.ts b/client/e2e/src/suites-local/plugins.e2e-spec.ts index 55f020c44..363c7f836 100644 --- a/client/e2e/src/suites-local/plugins.e2e-spec.ts +++ b/client/e2e/src/suites-local/plugins.e2e-spec.ts @@ -1,7 +1,7 @@ import { AdminPluginPage } from '../po/admin-plugin.po' import { LoginPage } from '../po/login.po' import { VideoUploadPage } from '../po/video-upload.po' -import { browserSleep, getCheckbox, waitServerUp } from '../utils' +import { getCheckbox, isMobileDevice, waitServerUp } from '../utils' describe('Plugins', () => { let videoUploadPage: VideoUploadPage @@ -24,7 +24,7 @@ describe('Plugins', () => { }) beforeEach(async () => { - loginPage = new LoginPage() + loginPage = new LoginPage(isMobileDevice()) videoUploadPage = new VideoUploadPage() adminPluginPage = new AdminPluginPage() @@ -34,7 +34,7 @@ describe('Plugins', () => { it('Should install hello world plugin', async () => { await loginPage.loginAsRootUser() - await adminPluginPage.navigateToSearch() + await adminPluginPage.navigateToPluginSearch() await adminPluginPage.search('hello-world') await adminPluginPage.installHelloWorld() await browser.refresh() @@ -42,7 +42,7 @@ describe('Plugins', () => { it('Should have checkbox in video edit page', async () => { await videoUploadPage.navigateTo() - await videoUploadPage.uploadVideo() + await videoUploadPage.uploadVideo('video.mp4') await $('span=Super field 4 in main tab').waitForDisplayed() @@ -54,6 +54,8 @@ describe('Plugins', () => { it('Should check the checkbox and be able to submit the video', async function () { const checkbox = await getPluginCheckbox() + + await checkbox.waitForClickable() await checkbox.click() await expectSubmitState({ disabled: false }) @@ -61,6 +63,8 @@ describe('Plugins', () => { it('Should uncheck the checkbox and not be able to submit the video', async function () { const checkbox = await getPluginCheckbox() + + await checkbox.waitForClickable() await checkbox.click() await expectSubmitState({ disabled: true })