merge from ecomp a88f0072 - Modern UI
Issue-ID: VID-378
Change-Id: Ibcb23dd27f550cf32ce2fe0239f0f496ae014ff6
Signed-off-by: Ittay Stern <ittay.stern@att.com>
diff --git a/vid-webpack-master/cypress/support/jsonBuilders/mocks/vid.mock.ts b/vid-webpack-master/cypress/support/jsonBuilders/mocks/vid.mock.ts
index 5bc02d1..8b25488 100644
--- a/vid-webpack-master/cypress/support/jsonBuilders/mocks/vid.mock.ts
+++ b/vid-webpack-master/cypress/support/jsonBuilders/mocks/vid.mock.ts
@@ -3,6 +3,9 @@
initVidMock: typeof initVidMock;
preventErrorsOnLoading : typeof preventErrorsOnLoading;
initCategoryParameter : typeof initCategoryParameter;
+ initAuditInfoMSO: typeof initAuditInfoMSO;
+ initAuditInfoMSOALaCarte: typeof initAuditInfoMSOALaCarte;
+ initAsyncInstantiation : typeof initAsyncInstantiation;
}
}
@@ -34,7 +37,7 @@
status : 200,
url : Cypress.config('baseUrl') + "/category_parameter**",
response : response ? response : res
- });
+ }).as('initCategoryParameters');
})
}
@@ -77,6 +80,34 @@
})
}
+function initAuditInfoMSOALaCarte(response? : JSON, delay?: number, status?: number) : void {
+ cy.readFile('../vid-automation/src/test/resources/a-la-carte/auditInfoMSOALaCarte.json').then((res) => {
+ cy.server()
+ .route({
+ method: 'GET',
+ delay : delay ? delay : 0,
+ status : status ? status : 200,
+ url : Cypress.config('baseUrl') + "/asyncInstantiation/auditStatus/**/mso**",
+ response : response ? response : res
+ }).as('initAuditInfoMSOAlaCarte');
+ })
+}
+
+function initAsyncInstantiation(response? : JSON, delay?: number, status?: number) : void {
+ cy.readFile('/cypress/support/jsonBuilders/mocks/jsons/basicAsyncInstantiation.json').then((res) => {
+ cy.server()
+ .route({
+ method: 'GET',
+ delay : delay ? delay : 0,
+ status : status ? status : 200,
+ url : Cypress.config('baseUrl') + "/asyncInstantiation",
+ response : response ? response : res
+ }).as('initAsyncInstantiation');
+ })
+}
+
+
+
function initVidMock(): void {
initGetToMenuInfo();
initCategoryParameter();
@@ -89,3 +120,6 @@
Cypress.Commands.add('initVidMock', initVidMock);
Cypress.Commands.add('preventErrorsOnLoading', preventErrorsOnLoading);
Cypress.Commands.add('initCategoryParameter', initCategoryParameter);
+Cypress.Commands.add('initAuditInfoMSO', initAuditInfoMSO);
+Cypress.Commands.add('initAuditInfoMSOALaCarte', initAuditInfoMSOALaCarte);
+Cypress.Commands.add('initAsyncInstantiation', initAsyncInstantiation);