From 7df7b31d97308f12f912412b2ba92c650628e5de Mon Sep 17 00:00:00 2001 From: Carlos Santos <4a.santos@gmail.com> Date: Fri, 23 May 2025 18:13:35 +0200 Subject: [PATCH] ov-components: add screenshot logging and delay in API directives tests --- openvidu-components-angular/e2e/api-directives.test.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/openvidu-components-angular/e2e/api-directives.test.ts b/openvidu-components-angular/e2e/api-directives.test.ts index 9b483592..c6286c78 100644 --- a/openvidu-components-angular/e2e/api-directives.test.ts +++ b/openvidu-components-angular/e2e/api-directives.test.ts @@ -27,6 +27,7 @@ describe('Testing API Directives', () => { // leaving room if connected await utils.leaveRoom(); } catch (error) {} + await browser.sleep(500); await browser.quit(); }); @@ -238,6 +239,8 @@ describe('Testing API Directives', () => { await utils.waitForElement('#videocam_off'); expect(await utils.isPresent('#videocam_off')).toBeTrue(); + console.log('data:image/png;base64,' + await browser.takeScreenshot()); + await utils.waitForElement('#video-poster'); expect(await utils.getNumberOfElements('video')).toEqual(0); }); @@ -265,7 +268,6 @@ describe('Testing API Directives', () => { // Checking if video is displayed await utils.checkVideoElementIsPresent(); - console.log('data:image/png;base64,' + await browser.takeScreenshot()); expect(await utils.getNumberOfElements('video')).toEqual(1); expect(await utils.getNumberOfElements('audio')).toEqual(0); @@ -275,6 +277,7 @@ describe('Testing API Directives', () => { await utils.clickOn('#join-button'); await utils.checkSessionIsPresent(); + console.log('data:image/png;base64,' + await browser.takeScreenshot()); expect(await utils.getNumberOfElements('video')).toEqual(1); expect(await utils.getNumberOfElements('audio')).toEqual(0);