From 4594cba0c53461bc1a273458e0a7a314da6bfb68 Mon Sep 17 00:00:00 2001 From: "andre.schmid" Date: Tue, 25 Jan 2022 19:38:32 +0000 Subject: Obtain and control VSP package upload status Obtain the upload status and control the upload from the frontend perspective. Change-Id: Idcc921cf592efea33df35c557afcfae827af3a39 Issue-ID: SDC-3862 Signed-off-by: andre.schmid --- .../test/softwareProduct/landingPage/landingPage.test.js | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'openecomp-ui/test/softwareProduct/landingPage/landingPage.test.js') diff --git a/openecomp-ui/test/softwareProduct/landingPage/landingPage.test.js b/openecomp-ui/test/softwareProduct/landingPage/landingPage.test.js index 2ef1d9fce8..de7db29ad7 100644 --- a/openecomp-ui/test/softwareProduct/landingPage/landingPage.test.js +++ b/openecomp-ui/test/softwareProduct/landingPage/landingPage.test.js @@ -39,6 +39,7 @@ describe('Software Product Landing Page: ', function () { let currentSoftwareProduct = {}, softwareProductCategories = [], currentScreen = {}, finalizedLicenseModelList, licenseAgreementList, featureGroupsList, qschema, qdata = {}; const dummyFunc = () => {}; + const fetchUploadStatusMock = () => { return Promise.resolve({ data: {} }) }; beforeAll(function() { finalizedLicenseModelList = FinalizedLicenseModelFactory.buildList(2); @@ -96,7 +97,8 @@ describe('Software Product Landing Page: ', function () { ...currentScreen.props, currentSoftwareProduct, componentsList: VSPComponentsFactory.buildList(2), - features: [{name:'EXTERNAL_LICENSE', active: true}] + features: [{name:'EXTERNAL_LICENSE', active: true}], + fetchUploadStatus: fetchUploadStatusMock }; const store = storeCreator(); @@ -113,7 +115,8 @@ describe('Software Product Landing Page: ', function () { ...currentScreen.props, currentSoftwareProduct, componentsList: VSPComponentsFactory.buildList(2), - features: [{name:'EXTERNAL_LICENSE', active: true}] + features: [{name:'EXTERNAL_LICENSE', active: true}], + fetchUploadStatus: fetchUploadStatusMock }; const e = { target: { value: 'INTERNAL' @@ -143,7 +146,8 @@ describe('Software Product Landing Page: ', function () { currentSoftwareProduct, ...currentScreen.props, componentsList: VSPComponentsFactory.buildList(2), - features: [{name:'EXTERNAL_LICENSE', active: true}] + features: [{name:'EXTERNAL_LICENSE', active: true}], + fetchUploadStatus: fetchUploadStatusMock }; const store = storeCreator(); @@ -171,7 +175,8 @@ describe('Software Product Landing Page: ', function () { onUploadConfirmation: dummyFunc, onUpload: dummyFunc, onInvalidFileSizeUpload: dummyFunc, - features: [{name:'EXTERNAL_LICENSE', active: true}] + features: [{name:'EXTERNAL_LICENSE', active: true}], + fetchUploadStatus: fetchUploadStatusMock }; const files = [ @@ -215,7 +220,8 @@ describe('Software Product Landing Page: ', function () { onUploadConfirmation: dummyFunc, onUpload: dummyFunc, onInvalidFileSizeUpload: dummyFunc, - features: [{name:'EXTERNAL_LICENSE', active: true}] + features: [{name:'EXTERNAL_LICENSE', active: true}], + fetchUploadStatus: fetchUploadStatusMock }; const store = storeCreator(); -- cgit 1.2.3-korg