From 60e246814415ee1daf838db78aff8afd53ce46f5 Mon Sep 17 00:00:00 2001 From: Ittay Stern Date: Thu, 4 Jun 2020 08:41:20 +0300 Subject: test COMPLETED_AND_PAUSED should have correct menu items Issue-ID: VID-821 Change-Id: I8d5301a9534345d83b06f33a9d2daca45a613922 Signed-off-by: Ittay Stern --- .../integration/iFrames/instantiationStatus.e2e.ts | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'vid-webpack-master') diff --git a/vid-webpack-master/cypress/integration/iFrames/instantiationStatus.e2e.ts b/vid-webpack-master/cypress/integration/iFrames/instantiationStatus.e2e.ts index 094ea83d4..b54ed0e66 100644 --- a/vid-webpack-master/cypress/integration/iFrames/instantiationStatus.e2e.ts +++ b/vid-webpack-master/cypress/integration/iFrames/instantiationStatus.e2e.ts @@ -102,6 +102,10 @@ describe('Instantiation status', function () { return cy.get('.dropdown-menu').find('.disabled').find(`[data-tests-id='${testId}']`); } + function getDropDownItemByDataTestId(testId:String) { + return cy.get('.dropdown-menu').find(`[data-tests-id='${testId}']`); + } + function clickOnTitleAndThenOnMenuWithJobId(jobId: string) { cy.getElementByDataTestsId("instantiation-status-title").click(); cy.get('#' + jobId).find('.menu-div').click({force: true}); @@ -141,13 +145,17 @@ describe('Instantiation status', function () { getDisabledDropDownItemByDataTestId('context-menu-hide').should('not.exist'); getDisabledDropDownItemByDataTestId('context-menu-audit-info').should('not.exist'); getDisabledDropDownItemByDataTestId(contextMenuCreateAnotherOne).should('exist'); + }); + + it('COMPLETED_AND_PAUSED should have correct menu items', function () { + cy.openIframe('app/ui/#/instantiationStatus'); //COMPLETED_AND_PAUSED clickOnTitleAndThenOnMenuWithJobId('850dc7d2-5240-437f-9bcd-b1ed7dc339d9'); - getDisabledDropDownItemByDataTestId('context-menu-retry').should('exist'); - getDisabledDropDownItemByDataTestId('context-menu-open').should('exist'); - getDisabledDropDownItemByDataTestId('context-menu-audit-info').should('exist'); - getDisabledDropDownItemByDataTestId(contextMenuCreateAnotherOne).should('exist'); + getDropDownItemByDataTestId('context-menu-retry').should('exist'); + getDropDownItemByDataTestId('context-menu-open').should('exist'); + getDropDownItemByDataTestId('context-menu-audit-info').should('exist'); + getDropDownItemByDataTestId(contextMenuCreateAnotherOne).should('exist'); }); it('clicking on create another one item, go to expected url', function () { -- cgit 1.2.3-korg