From 51abe8acdd924bb3ad260966723210b6d5b8e870 Mon Sep 17 00:00:00 2001 From: Alexey Sandler Date: Mon, 30 Mar 2020 00:09:26 +0300 Subject: add test that verify delete and upgrade of the not upgraded vfm's add cypress test that verify delete and upgrade of the not upgraded vfm's on a single click Issue-ID: VID-798 Signed-off-by: Alexey Sandler Change-Id: I293779c3bd48215b6830a99be9a423ce7cb29a5d Signed-off-by: Alexey Sandler --- .../integration/iFrames/viewEditUpgradeVfModule.e2e.ts | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'vid-webpack-master/cypress/integration') diff --git a/vid-webpack-master/cypress/integration/iFrames/viewEditUpgradeVfModule.e2e.ts b/vid-webpack-master/cypress/integration/iFrames/viewEditUpgradeVfModule.e2e.ts index b949e6648..6fb667588 100644 --- a/vid-webpack-master/cypress/integration/iFrames/viewEditUpgradeVfModule.e2e.ts +++ b/vid-webpack-master/cypress/integration/iFrames/viewEditUpgradeVfModule.e2e.ts @@ -143,7 +143,8 @@ describe('View Edit Page: Upgrade VFModule', function () { afterEach(() => { cy.screenshot(); }); - it(`Delete not upgraded VFM`, () => { + + it(`Delete not upgraded VFM and upgrade another in a single click`, () => { const serviceType = 'Emanuel'; const subscriberId = 'a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb'; @@ -172,8 +173,11 @@ describe('View Edit Page: Upgrade VFModule', function () { ).as("newestModelVersion2"); cy.openIframe(`app/ui/#/servicePlanning/EDIT?serviceModelId=${serviceModelId}&subscriberId=${subscriberId}&serviceType=${serviceType}&serviceInstanceId=${serviceInstanceId}`); - cy.getElementByDataTestsId(`node-c449aaf8-2467-41a9-9015-730ab48ca19b-mdns012220200..Mdns01222020..dns_az_01..module-1-menu-btn`).click() - .drawingBoardTreeClickOnContextMenuOptionByName("Delete"); + + deleteTheVfm(`node-c449aaf8-2467-41a9-9015-730ab48ca19b-mdns012220200..Mdns01222020..dns_az_01..module-1`); + + upgradeTheVFM(`node-04b21d26-9780-4956-8329-b22b049329f4-xbitestmodulereplace0..XbiTestModuleReplace..base_ocg..module-0`, false); + cy.getElementByDataTestsId('delete-status-type').contains('Delete'); mockAsyncBulkResponse(); @@ -302,6 +306,11 @@ describe('View Edit Page: Upgrade VFModule', function () { }).as("expectLatestServiceModelUpgradeVersion"); } + function deleteTheVfm(treeNodeId: string) { + cy.getElementByDataTestsId(`${treeNodeId}-menu-btn`).click() + .drawingBoardTreeClickOnContextMenuOptionByName("Delete"); + } + function upgradeTheVFM(treeNodeId: string, shouldVGCheckboxExist :boolean) { cy.getElementByDataTestsId(`${treeNodeId}-menu-btn`).click() .drawingBoardTreeClickOnContextMenuOptionByName("Upgrade"); -- cgit 1.2.3-korg