private String serviceModelName;
private String serviceModelVersionId;
private String platformName;
+ private String lineOfBusinessName;
+
public PresetMSOCreateNetworkALaCarteServiceCypress2(String overrideRequestId, String serviceInstanceId, String networkName) {
this(overrideRequestId, serviceInstanceId, networkName, "ComplexService", "6e59c5de-f052-46fa-aa7e-2fca9d674c44",
- "xxx1");
+ "xxx1", "zzz1");
}
public PresetMSOCreateNetworkALaCarteServiceCypress2(String overrideRequestId, String serviceInstanceId,
- String networkName, String serviceModelName, String serviceModelVersionId, String platformName) {
+ String networkName, String serviceModelName, String serviceModelVersionId, String platformName,
+ String lineOfBusinessName) {
super(overrideRequestId);
this.serviceInstanceId = serviceInstanceId;
this.networkName = networkName;
this.serviceModelName = serviceModelName;
this.serviceModelVersionId = serviceModelVersionId;
this.platformName = platformName;
+ this.lineOfBusinessName = lineOfBusinessName;
}
@Override
"\"source\":\"VID\"," +
"\"suppressRollback\":false," +
"\"requestorId\":\"us16807000\"}," +
- "\"lineOfBusiness\":{\"lineOfBusinessName\":\"zzz1\"}," +
+ "\"lineOfBusiness\":{\"lineOfBusinessName\":\"" + lineOfBusinessName + "\"}," +
"\"cloudConfiguration\":" +
"{\"lcpCloudRegionId\":\"hvf6\"," +
addCloudOwnerIfNeeded() +
if(!isNetwork){
SelectOption.byTestIdAndVisibleText("TYLER SILVIA", Constants.ViewEdit.PRODUCT_FAMILY_SELECT_TESTS_ID);
browseASDCPage.selectProductFamily("e433710f-9217-458d-a79d-1c7aff376d89");
+ browseASDCPage.selectLineOfBusiness("ONAP");
+ } else {
+ SelectOption.selectOptionsFromMultiselectById("multi-lineOfBusiness",ImmutableList.of("ONAP"));
}
- browseASDCPage.selectLineOfBusiness("ONAP");
assertSetButtonEnabled(VNF_SET_BUTTON_TEST_ID);
browseASDCPage.setLegacyRegion("some legacy region");
new PresetMSOOrchestrationRequestGet(COMPLETE, deleteRequestId),
new PresetMSOCreateNetworkALaCarteServiceCypress2(createRequestId, serviceInstanceId,
"ExtVL", "action-data",
- "6b528779-44a3-4472-bdff-9cd15ec93450", "xxx1,platform"),
+ "6b528779-44a3-4472-bdff-9cd15ec93450", "xxx1,platform", "zzz1,ONAP"),
new PresetMSOOrchestrationRequestGet(COMPLETE, createRequestId),
PresetAAIGetCloudOwnersByCloudRegionId.PRESET_MTN6_TO_ATT_AIC
), RegistrationStrategy.CLEAR_THEN_SET);
"lcpCloudRegionId":"hvf6",
"tenantId":"229bcdc6eaeb4ca59d55221141d01f8e",
"platformName":"xxx1,platform" ,
- "lineOfBusiness":"zzz1",
+ "lineOfBusiness":"zzz1,ONAP",
"instanceParams":[
{
cy.selectDropdownOptionByText('tenant', 'USP-SIP-IC-24335-T-01');
cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1');
- cy.selectPlatformValue('xxx1');
+ cy.selectPlatformValue(`xxx1`);
cy.getElementByDataTestsId('form-set').click({force: true}).then(() => {
cy.getElementByDataTestsId(vnfMenuBtnDataTestId).click({force: true}).then(() => {
cy.getElementByDataTestsId('context-menu-edit').click({force: true});
- cy.selectPlatformValue('platform');
+ cy.selectPlatformValue(`platform`);
cy.getElementByDataTestsId('form-set').click({force: true}).then(() => {
cy.getReduxState().then((state) => {
cy.openIframe('app/ui/#/servicePlanning?serviceModelId=2f80c596-27e5-4ca9-b5bb-e03a7fd4c0fd');
cy.getElementByDataTestsId("node-ExtVL 0-add-btn").click({force: true});
- cy.selectPlatformValue("xxx1");
+ cy.selectPlatformValue(`xxx1`);
cy.selectDropdownOptionByText("lcpRegion", "AAIAIC25");
cy.selectDropdownOptionByText("tenant", "USP-SIP-IC-24335-T-01");
cy.selectDropdownOptionByText("productFamily", "ERICA");
- cy.selectDropdownOptionByText("lineOfBusiness", "zzz1");
+ cy.selectMultiselectValue("multi-lineOfBusiness", "multi-lineOfBusiness-zzz1");
cy.typeToInput("lcpRegionText", "lcpRegionText");
cy.getElementByDataTestsId('form-set').click({force: true}).then(() => {
cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1');
cy.selectDropdownOptionByText('lcpRegion', 'foo-name');
cy.selectDropdownOptionByText('tenant', 'tenantID');
- cy.selectPlatformValue('xxx1');
+ cy.selectPlatformValue(`xxx1`);
cy.getElementByDataTestsId('form-set').click({force: true}).then(() => {
const vnfMenuBtnDataTestId = 'node-69e09f68-8b63-4cc9-b9ff-860960b5db09-2017-488_PASQUALE-vPE 0-menu-btn';
cy.selectDropdownOptionByText('lcpRegion', 'hvf6');
cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-STTest2');
cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1');
- cy.selectPlatformValue('xxx1');
+ cy.selectPlatformValue(`xxx1`);
cy.getElementByDataTestsId('form-set').click({force: true}).then(() => {
const vnfName = '2017-488_PASQUALE-vPE 0';
let vfModulesNames: Array<string> = [
cy.selectDropdownOptionByText('lcpRegion', 'hvf6');
cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-testalexandria');
cy.selectDropdownOptionByText('lineOfBusiness', 'ONAP');
- cy.selectPlatformValue('platform');
+ cy.selectPlatformValue(`platform`);
cy.genericFormSubmitForm();
cy.getElementByDataTestsId('node-afacccf6-397d-45d6-b5ae-94c39734b168-2017-388_PASQUALE-vPE 0').contains('<Automatically Assigned>');
cy.selectDropdownOptionByText('productFamily', 'ERICA');
cy.selectDropdownOptionByText('lcpRegion', 'hvf6');
cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-testalexandria');
- cy.selectDropdownOptionByText('lineOfBusiness', 'ONAP')
- cy.selectPlatformValue('platform');
+ cy.selectLobValue("ONAP");
+ cy.selectPlatformValue(`platform`);
cy.genericFormSubmitForm();
.getElementByDataTestsId("lcpRegion").should('contain', 'hvf6')
.getElementByDataTestsId("lineOfBusiness").should('contain', 'zzz1')
.getElementByDataTestsId("rollback").should('contain', 'Rollback')
- .checkPlatformValue('xxx1')
+ cy.checkPlatformValue(`xxx1`)
.getElementByDataTestsId("cancelButton").click();
cy.editNode("node-c5b26cc1-a66f-4b69-aa23-6abc7c647c88-vprobe_nc_vnf0..VprobeNcVnf..FE_base_module..module-0")
// edit vnf
cy.editNode("node-21ae311e-432f-4c54-b855-446d0b8ded72-vProbe_NC_VNF 0");
if (testCase.modifySomeValues) {
- cy.selectPlatformValue('platform');
+ cy.selectPlatformValue(`platform`);
cy.selectDropdownOptionByText("tenant", "CESAR-100-D-spjg61909");
}
cy.getElementByDataTestsId('form-set').click();
cy.checkIsOptionSelected('productFamily', 'a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb');
cy.checkIsOptionSelected('lcpRegion', 'hvf6');
cy.checkIsOptionSelected('tenant', '229bcdc6eaeb4ca59d55221141d01f8e');
- cy.checkIsOptionSelected('lineOfBusiness', 'zzz1');
+ cy.checkLobValue( "zzz1");
cy.checkPlatformValue('xxx1');
//change platform value
cy.selectPlatformValue('platform');
cy.getElementByDataTestsId('numberButton').contains('1');
cy.getElementByDataTestsId('node-ddc3f20c-08b5-40fd-af72-c6d14636b986-ExtVL 0-menu-btn').click({force: true})
.getElementByDataTestsId('context-menu-edit').click({force: true}).then(() => {
- cy.checkPlatformValue( 'platform');
+ cy.checkPlatformValue('platform');
// cancel button should close the dialog
- cy.getElementByDataTestsId('cancelButton').click({force: true}).then(() => {
+ cy.getElementByDataTestsId('cancelButton').click({force: true, multiple: true}).then(() => {
// duplicate network
cy.getElementByDataTestsId('node-ddc3f20c-08b5-40fd-af72-c6d14636b986-ExtVL 0-menu-btn').click({force: true})
.getElementByDataTestsId('context-menu-duplicate').click({force: true}).then(() => {
cy.selectDropdownOptionByText('productFamily', 'Emanuel');
cy.selectDropdownOptionByText('lcpRegion', 'hvf6');
cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-STTest2');
- cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1');
+ cy.selectLobValue("zzz1");
cy.selectPlatformValue('xxx1');
cy.getElementByDataTestsId('form-set').should('not.have.attr', 'disabled');
//add one network
cy.getElementByDataTestsId('node-ExtVL 0-add-btn').click({force: true}).then(() => {
verifyServiceModelNameInModelInfo();
- cy.fillNetworkPopup(true);
+ cy.fillNetworkPopup(true, true);
});
"FLAG_ADVANCED_PORTS_FILTER": true,
"FLAG_REGION_ID_FROM_REMOTE": true,
"FLAG_ADD_MSO_TESTAPI_FIELD": true,
- "FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT": true
+ "FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT" :true,
+ "FLAG_2006_NETWORK_LOB_MULTI_SELECT": true,
},
"type": "[FLAGS] Update"
},
cy.selectDropdownOptionByText('lcpRegion', 'hvf6');
cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-STTest2');
cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1');
- cy.selectPlatformValue('xxx1');
+ cy.selectPlatformValue(`xxx1`);
})
});
"FLAG_2004_CREATE_ANOTHER_INSTANCE_FROM_TEMPLATE": true,
"FLAG_2006_VFM_SDNC_PRELOAD_FILES" : true,
"FLAG_2006_VFMODULE_TAKES_TENANT_AND_REGION_FROM_VNF": true,
- "FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT" :true
+ "FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT" :true,
+ "FLAG_2006_NETWORK_LOB_MULTI_SELECT" : true
}
}
}
-function fillNetworkPopup(shouldSelectAdditionalPlatform: boolean = false): Cypress.Chainable<any> {
+function fillNetworkPopup(shouldSelectAdditionalPlatform: boolean = false, shouldSelectAdditionalLob: boolean = false): Cypress.Chainable<any> {
cy.selectDropdownOptionByText('productFamily', 'Emanuel');
cy.selectDropdownOptionByText('lcpRegion', 'hvf6');
cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-STTest2');
- cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1');
- cy.selectPlatformValue('xxx1');
+ cy.selectLobValue("zzz1");
+ cy.selectPlatformValue(`xxx1`);
if(shouldSelectAdditionalPlatform){
- cy.selectPlatformValue('platform');
+ cy.selectPlatformValue(`platform`);
+ }
+ if(shouldSelectAdditionalLob){
+ cy.selectLobValue("ONAP");
}
return cy.getElementByDataTestsId('form-set').click({force : true}).then((done)=>{
return done;
cy.selectDropdownOptionByText('lcpRegion', 'hvf6');
cy.selectDropdownOptionByText('tenant', 'AIN Web Tool-15-D-STTest2');
cy.selectDropdownOptionByText('lineOfBusiness', 'zzz1');
- cy.selectPlatformValue('xxx1');
+ cy.selectPlatformValue(`xxx1`);
return cy.getElementByDataTestsId('form-set').click({force : true}).then((done)=>{
return done;
});
declare namespace Cypress {
interface Chainable {
genericFormSubmitForm: typeof genericFormSubmitForm
+ selectMultiselectValue: typeof selectMultiselectValue
selectPlatformValue: typeof selectPlatformValue
+ selectLobValue: typeof selectLobValue
+ checkMultiSelectValue: typeof checkMultiSelectValue
checkPlatformValue: typeof checkPlatformValue
+ checkLobValue: typeof checkLobValue
+
}
}
-function selectPlatformValue(selectOption: string) {
- cy.getElementByDataTestsId("multi-selectPlatform").get('.c-btn').click({force: true});
- cy.getElementByDataTestsId(`multi-selectPlatform-${selectOption}`).click();
- cy.getElementByDataTestsId("multi-selectPlatform").get('.c-btn').click({force: true});
+function selectMultiselectValue(dataTestsId: string , selectOptionId: string) {
+ cy.getElementByDataTestsId(dataTestsId).find('.c-btn').eq(0).click({force: true})
+ cy.getElementByDataTestsId(selectOptionId).click();
+ cy.getElementByDataTestsId(dataTestsId).find('.c-btn').eq(0).click({force: true})
+}
+
+function selectPlatformValue(selectOptionId: string) {
+ selectMultiselectValue("multi-selectPlatform", "multi-selectPlatform-" + selectOptionId)
+}
+
+function selectLobValue(selectOptionId: string) {
+ selectMultiselectValue("multi-lineOfBusiness", "multi-lineOfBusiness-" + selectOptionId)
+
}
function checkPlatformValue(value: string){
- return cy.getElementByDataTestsId("multi-selectPlatform").should("contain", value)
+ return checkMultiSelectValue("multi-selectPlatform", value)
+}
+
+function checkLobValue(value: string){
+ return checkMultiSelectValue("multi-lineOfBusiness", value)
+}
+
+function checkMultiSelectValue(dataTestsId: string, value: string) {
+ return cy.getElementByDataTestsId(dataTestsId).should("contain", value)
}
function genericFormSubmitForm(): Chainable<any> {
Cypress.Commands.add('genericFormSubmitForm', genericFormSubmitForm);
+Cypress.Commands.add('selectMultiselectValue', selectMultiselectValue);
Cypress.Commands.add('selectPlatformValue', selectPlatformValue);
+Cypress.Commands.add('selectLobValue', selectLobValue);
+Cypress.Commands.add('checkMultiSelectValue', checkMultiSelectValue);
Cypress.Commands.add('checkPlatformValue', checkPlatformValue);
+Cypress.Commands.add('checkLobValue', checkLobValue);
+
result.push(this._sharedControllersService.getLegacyRegion(networkInstance));
result.push(this._sharedControllersService.getTenantControl(serviceId, networkInstance));
result.push(this._sharedControllersService.getPlatformMultiselectControl(networkInstance, result, flags['FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT']));
- result.push(this._sharedControllersService.getLineOfBusinessControl(networkInstance));
+ result.push(this._sharedControllersService.getMultiSelectLineOfBusinessControl(networkInstance, flags['FLAG_2006_NETWORK_LOB_MULTI_SELECT']));
}
return result;
result.push(this._sharedControllersService.getLegacyRegion(networkInstance));
result.push(this._sharedControllersService.getTenantControl(serviceId, networkInstance));
result.push(this._sharedControllersService.getPlatformMultiselectControl(networkInstance, result, flags['FLAG_2006_NETWORK_PLATFORM_MULTI_SELECT']));
- result.push(this._sharedControllersService.getLineOfBusinessControl(networkInstance));
+ result.push(this._sharedControllersService.getMultiSelectLineOfBusinessControl(networkInstance, flags['FLAG_2006_NETWORK_LOB_MULTI_SELECT']));
result.push(this._sharedControllersService.getRollbackOnFailureControl(networkInstance));
}
return result;
return this.getLineOfBusinessControlInternal(undefined, instance);
};
+ getMultiSelectLineOfBusinessControl = (instance: any, isMultiSelected: boolean): MultiselectFormControl => {
+ return this.getLobMultiselectControl(instance, isMultiSelected);
+ };
+
getLineOfBusinessByOwningEntityControl = (instance?: any, serviceId?: string, controls?: FormControlModel[]): DropdownFormControl => {
const service = this._store.getState().service.serviceInstance[serviceId];
const owningEntityName: string = service.owningEntityName;
);
};
- getLobMultiselectControl = (instance: any, controls: FormControlModel[], isMultiSelected: boolean) : MultiselectFormControl => {
+ getLobMultiselectControl = (instance: any, isMultiSelected: boolean) : MultiselectFormControl => {
return this.getMultiSelectFormControl(
'lineOfBusiness',
'Line of business',