diff options
author | brunomilitzer <bruno.militzer@est.tech> | 2022-02-25 10:38:47 +0000 |
---|---|---|
committer | brunomilitzer <bruno.militzer@est.tech> | 2022-02-28 15:11:16 +0000 |
commit | 4651d908fe8fa83801a8df4d6e83e4eb25073f46 (patch) | |
tree | 363290263a096b70c4dd78c84ecc8b1b07730e15 /gui-clamp/ui-react/src/components/dialogs | |
parent | 4a4a638d6d0336134cdb4cdab093054f3b3f09f9 (diff) |
Renamed Control Loop to ACM
Issue-ID: POLICY-3940
Change-Id: I37d768ac339e4e354a369fcb659bf36da861d7aa
Signed-off-by: brunomilitzer <bruno.militzer@est.tech>
Diffstat (limited to 'gui-clamp/ui-react/src/components/dialogs')
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/AccordionHeader.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/AccordionHeader.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/AccordionHeader.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/AccordionHeader.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/ChangeOrderStateModal.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/ChangeOrderStateModal.js) | 16 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/ChangeOrderStateModal.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/ChangeOrderStateModal.test.js) | 27 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/CommissioningModal.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/CommissioningModal.js) | 12 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/CommissioningModal.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/CommissioningModal.test.js) | 10 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/DeleteToscaTemplate.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/DeleteToscaTemplate.js) | 4 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/DeleteToscaTemplate.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/DeleteToscaTemplate.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/GetLocalToscaFileForUpload.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetLocalToscaFileForUpload.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/GetLocalToscaFileForUpload.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetLocalToscaFileForUpload.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/GetToscaTemplate.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetToscaTemplate.js) | 4 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/GetToscaTemplate.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetToscaTemplate.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstancePropertiesModal.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstancePropertiesModal.js) | 8 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstancePropertiesModal.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstancePropertiesModal.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElementItem.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElementItem.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElementItem.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElementItem.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElements.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElements.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElements.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElements.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationItem.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationItem.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationItem.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationItem.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationManagementModal.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationManagementModal.js) | 19 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationManagementModal.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationManagementModal.test.js) | 10 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationOrderStateChangeItem.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationOrderStateChangeItem.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationOrderStateChangeItem.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationOrderStateChangeItem.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/MonitorInstantiation.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/MonitorInstantiation.js) | 26 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/MonitorInstantiation.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/MonitorInstantiation.test.js) | 6 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/ReadAndConvertYaml.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/ReadAndConvertYaml.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/ReadAndConvertYaml.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/ReadAndConvertYaml.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/UploadToscaFile.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/UploadToscaFile.js) | 4 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/UploadToscaFile.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/UploadToscaFile.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/AccordionHeader.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/AccordionHeader.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/ChangeOrderStateModal.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/ChangeOrderStateModal.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/CommissioningModal.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/CommissioningModal.test.js.snap) | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/DeleteToscaTemplate.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/DeleteToscaTemplate.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/GetLocalToscaFileForUpload.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/GetLocalToscaFileForUpload.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/GetToscaTemplate.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/GetToscaTemplate.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstancePropertiesModal.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstancePropertiesModal.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationElementItem.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationElementItem.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationElements.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationElements.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationItem.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationItem.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationManagementModal.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationManagementModal.test.js.snap) | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationOrderStateChangeItem.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationOrderStateChangeItem.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/MonitorInstantiation.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/MonitorInstantiation.test.js.snap) | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/ReadAndConvertYaml.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/ReadAndConvertYaml.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/UploadToscaFile.test.js.snap (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/UploadToscaFile.test.js.snap) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/acmList.json (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/controlLoopList.json) | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/commonProps.json (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/commonProps.json) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/fullTemplate.json (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/fullTemplate.json) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/instanceProps.json (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/instanceProps.json) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/jsonEditorData.json (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/jsonEditorData.json) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/orderedStateJson.json (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/orderedStateJson.json) | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/utils/CommissioningUtils.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/CommissioningUtils.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/utils/CommissioningUtils.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/CommissioningUtils.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/utils/InstantiationUtils.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/InstantiationUtils.js) | 13 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/ACM/utils/InstantiationUtils.test.js (renamed from gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/InstantiationUtils.test.js) | 0 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/InstantiationManagementModal.test.js | 69 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/PerformActions.js | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/Policy/PolicyEditor.test.js | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/Policy/PolicyModal.test.js | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/Policy/ToscaViewer.test.js | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/Policy/__snapshots__/PolicyEditor.test.js.snap | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/Policy/toscaInstantiationData.test.json | 2 | ||||
-rw-r--r-- | gui-clamp/ui-react/src/components/dialogs/__snapshots__/InstantiationManagementModal.test.js.snap | 114 |
63 files changed, 91 insertions, 273 deletions
diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/AccordionHeader.js b/gui-clamp/ui-react/src/components/dialogs/ACM/AccordionHeader.js index a34b5b3..a34b5b3 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/AccordionHeader.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/AccordionHeader.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/AccordionHeader.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/AccordionHeader.test.js index 987f1fc..987f1fc 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/AccordionHeader.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/AccordionHeader.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/ChangeOrderStateModal.js b/gui-clamp/ui-react/src/components/dialogs/ACM/ChangeOrderStateModal.js index 3486ebf..0c9e8b7 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/ChangeOrderStateModal.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/ChangeOrderStateModal.js @@ -22,7 +22,7 @@ import Modal from "react-bootstrap/Modal"; import Button from "react-bootstrap/Button"; import React, { useEffect, useState } from "react"; import InstantiationOrderStateChangeItem from "./InstantiationOrderStateChangeItem"; -import ControlLoopService from "../../../api/ControlLoopService"; +import ACMService from "../../../api/ACMService"; import { Alert, Container, Dropdown } from "react-bootstrap"; const ModalStyled = styled(Modal)` @@ -48,7 +48,7 @@ const AlertStyled = styled(Alert)` const ChangeOrderStateModal = (props) => { const [show, setShow] = useState(true); - const [controlLoopIdentifierList, setControlLoopIdentifierList] = useState([]); + const [ACMIdentifierList, setACMIdentifierList] = useState([]); const [orderedState, setOrderedState] = useState(''); const [toscaOrderStateObject, setToscaOrderStateObject] = useState({}); const [instantiationOrderStateError, setInstantiationOrderStateError] = useState(false); @@ -57,7 +57,7 @@ const ChangeOrderStateModal = (props) => { useEffect(async () => { - const instantiationOrderState = await ControlLoopService.getInstanceOrderState( + const instantiationOrderState = await ACMService.getInstanceOrderState( props.location.instantiationName, props.location.instantiationVersion) .catch(error => error.message); @@ -66,11 +66,11 @@ const ChangeOrderStateModal = (props) => { console.log(orderStateJson); - if (!instantiationOrderState.ok || orderStateJson['controlLoopIdentifierList'].length === 0) { + if (!instantiationOrderState.ok || orderStateJson['automationCompositionIdentifierList'].length === 0) { setInstantiationOrderStateError(true); setInstantiationOrderStateMsgError(orderStateJson); } else { - setControlLoopIdentifierList(orderStateJson['controlLoopIdentifierList']); + setACMIdentifierList(orderStateJson['automationCompositionIdentifierList']); setOrderedState(orderStateJson['orderedState']); } }, []); @@ -80,7 +80,7 @@ const ChangeOrderStateModal = (props) => { const stateChangeObject = { orderedState: event, - controlLoopIdentifierList: controlLoopIdentifierList + automationCompositionIdentifierList: ACMIdentifierList } setToscaOrderStateObject(stateChangeObject); setOrderedState(event); @@ -89,7 +89,7 @@ const ChangeOrderStateModal = (props) => { const handleSave = async () => { console.log("handleSave called"); - const response = await ControlLoopService.changeInstanceOrderState(toscaOrderStateObject) + const response = await ACMService.changeInstanceOrderState(toscaOrderStateObject) .catch(error => error.message); if (response.ok) { @@ -148,7 +148,7 @@ const ChangeOrderStateModal = (props) => { </Dropdown.Menu> </Dropdown> { - controlLoopIdentifierList.map((clIdList, index) => ( + ACMIdentifierList.map((clIdList, index) => ( <InstantiationOrderStateChangeItem title={ clIdList.name } orderState={ orderedState } index={ index } key={ index }/> )) } diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/ChangeOrderStateModal.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/ChangeOrderStateModal.test.js index 63c6a60..598e6e3 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/ChangeOrderStateModal.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/ChangeOrderStateModal.test.js @@ -23,12 +23,13 @@ import toJson from "enzyme-to-json"; import ChangeOrderStateModal from "./ChangeOrderStateModal"; import { createMemoryHistory } from "history"; import { act } from "react-dom/test-utils"; -import clLoopList from "./testFiles/controlLoopList.json"; +import acmList from "./testFiles/acmList.json"; import orderedStateJson from "./testFiles/orderedStateJson.json"; -import ControlLoopService from "../../../api/ControlLoopService"; +import ACMService from "../../../api/ACMService"; let logSpy = jest.spyOn(console, 'log') const oldWindowLocation = window.location + describe('Verify ChangeOrderStateModal', () => { const flushPromises = () => new Promise(setImmediate); @@ -144,7 +145,7 @@ describe('Verify ChangeOrderStateModal', () => { it('handleSave called when save button clicked and response is ok', async () => { jest.resetAllMocks() - const getInstanceOrderStateSpy = jest.spyOn(ControlLoopService, 'getInstanceOrderState') + const getInstanceOrderStateSpy = jest.spyOn(ACMService, 'getInstanceOrderState') .mockImplementationOnce(() => { return Promise.resolve({ ok: true, @@ -157,14 +158,14 @@ describe('Verify ChangeOrderStateModal', () => { } ) - const changeInstanceOrderStateSpy = jest.spyOn(ControlLoopService, 'changeInstanceOrderState') + const changeInstanceOrderStateSpy = jest.spyOn(ACMService, 'changeInstanceOrderState') .mockImplementationOnce(() => { return Promise.resolve({ ok: true, status: 200, text: () => "OK", json: () => { - return Promise.resolve(clLoopList) + return Promise.resolve(acmList) } }) } @@ -172,7 +173,7 @@ describe('Verify ChangeOrderStateModal', () => { const component = mount(<ChangeOrderStateModal location={window.location}/>) - await act( async () => { + act( async () => { component.find('[variant="primary"]').simulate('click'); await expect(getInstanceOrderStateSpy).toHaveBeenCalled() await expect(changeInstanceOrderStateSpy).toHaveBeenCalled() @@ -183,7 +184,7 @@ describe('Verify ChangeOrderStateModal', () => { it('handleSave called when save button clicked and response is not ok', async () => { jest.resetAllMocks() - const getInstanceOrderStateSpy = jest.spyOn(ControlLoopService, 'getInstanceOrderState') + const getInstanceOrderStateSpy = jest.spyOn(ACMService, 'getInstanceOrderState') .mockImplementationOnce(() => { return Promise.resolve({ ok: true, @@ -196,14 +197,14 @@ describe('Verify ChangeOrderStateModal', () => { } ) - const changeInstanceOrderStateSpy = jest.spyOn(ControlLoopService, 'changeInstanceOrderState') + const changeInstanceOrderStateSpy = jest.spyOn(ACMService, 'changeInstanceOrderState') .mockImplementationOnce(() => { return Promise.resolve({ ok: false, status: 200, text: () => "OK", json: () => { - return Promise.resolve(clLoopList) + return Promise.resolve(acmList) } }) } @@ -222,7 +223,7 @@ describe('Verify ChangeOrderStateModal', () => { it('Check useEffect is being called', async () => { jest.resetAllMocks() - jest.spyOn(ControlLoopService, 'getInstanceOrderState') + jest.spyOn(ACMService, 'getInstanceOrderState') .mockImplementationOnce(() => { return Promise.resolve({ ok: true, @@ -235,14 +236,14 @@ describe('Verify ChangeOrderStateModal', () => { } ) - jest.spyOn(ControlLoopService, 'changeInstanceOrderState') + jest.spyOn(ACMService, 'changeInstanceOrderState') .mockImplementationOnce(() => { return Promise.resolve({ ok: true, status: 200, text: () => "OK", json: () => { - return Promise.resolve(clLoopList) + return Promise.resolve(acmList) } }) } @@ -251,7 +252,7 @@ describe('Verify ChangeOrderStateModal', () => { const component = mount(<ChangeOrderStateModal location={window.location}/>) const useEffect = jest.spyOn(React, "useEffect"); - await act(async () => { + act(async () => { await flushPromises() component.update() await expect(useEffect).toHaveBeenCalled(); diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/CommissioningModal.js b/gui-clamp/ui-react/src/components/dialogs/ACM/CommissioningModal.js index 4f8aaae..db71cd9 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/CommissioningModal.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/CommissioningModal.js @@ -21,7 +21,7 @@ import Modal from "react-bootstrap/Modal"; import Button from "react-bootstrap/Button"; import React, { useEffect, useState } from "react"; import styled from "styled-components"; -import ControlLoopService from "../../../api/ControlLoopService"; +import ACMService from "../../../api/ACMService"; import { Alert } from "react-bootstrap"; import CommissioningUtils from "./utils/CommissioningUtils"; @@ -60,9 +60,9 @@ const CommissioningModal = (props) => { const version = '1.0.0'; useEffect(async () => { - const toscaTemplateResponse = await ControlLoopService.getToscaTemplate(name, version) + const toscaTemplateResponse = await ACMService.getToscaTemplate(name, version) .catch(error => error.message); - const toscaCommonProperties = await ControlLoopService.getCommonOrInstanceProperties(name, version, true) + const toscaCommonProperties = await ACMService.getCommonOrInstanceProperties(name, version, true) .catch(error => error.message); if (!toscaCommonProperties.ok) { @@ -109,9 +109,9 @@ const CommissioningModal = (props) => { console.log("handleCommission called") - await ControlLoopService.deleteToscaTemplate('ToscaServiceTemplateSimple', "1.0.0") + await ACMService.deleteToscaTemplate('ToscaServiceTemplateSimple', "1.0.0") - const recommissioningResponse = await ControlLoopService.uploadToscaFile(fullToscaTemplate) + const recommissioningResponse = await ACMService.uploadToscaFile(fullToscaTemplate) await receiveResponseFromCommissioning(recommissioningResponse) } @@ -128,7 +128,7 @@ const CommissioningModal = (props) => { backdrop="static" keyboard={ false }> <Modal.Header closeButton> - <Modal.Title>Change Control Loop Common Properties</Modal.Title> + <Modal.Title>Change ACM Common Properties</Modal.Title> </Modal.Header> <br/> <div style={ { padding: '5px 5px 0px 5px' } }> diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/CommissioningModal.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/CommissioningModal.test.js index 9642145..e3a50be 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/CommissioningModal.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/CommissioningModal.test.js @@ -25,7 +25,7 @@ import { createMemoryHistory } from "history"; import CommissioningModal from "./CommissioningModal"; import commonProps from "./testFiles/commonProps.json"; import fullTemp from "./testFiles/fullTemplate.json"; -import ControlLoopService from "../../../api/ControlLoopService"; +import ACMService from "../../../api/ACMService"; let logSpy = jest.spyOn(console, 'log') const commonProperties = JSON.parse(JSON.stringify(commonProps)) @@ -97,7 +97,7 @@ describe('Verify CommissioningModal', () => { }); it('getToscaTemplate gets called in useEffect with error', async() => { - const fetchMock = jest.spyOn(ControlLoopService, 'getToscaTemplate').mockImplementation(() => Promise.resolve({ + const fetchMock = jest.spyOn(ACMService, 'getToscaTemplate').mockImplementation(() => Promise.resolve({ ok: false, status: 200, text: () => "OK", @@ -111,7 +111,7 @@ describe('Verify CommissioningModal', () => { }); it('getCommonProperties gets called in useEffect with error', async() => { - const fetchMock = jest.spyOn(ControlLoopService, 'getToscaTemplate').mockImplementation(() => Promise.resolve({ + const fetchMock = jest.spyOn(ACMService, 'getToscaTemplate').mockImplementation(() => Promise.resolve({ ok: false, status: 200, text: () => "OK", @@ -193,7 +193,7 @@ describe('Verify CommissioningModal', () => { }); it('test handleCommission called on click', async () => { - const deleteToscaTemplateSpy = jest.spyOn(ControlLoopService, 'deleteToscaTemplate').mockImplementation(() => { + const deleteToscaTemplateSpy = jest.spyOn(ACMService, 'deleteToscaTemplate').mockImplementation(() => { Promise.resolve({ ok: true, status: 200, @@ -201,7 +201,7 @@ describe('Verify CommissioningModal', () => { json: () => "{handleCommissioning}" }) }) - const uploadToscaTemplateSpy = jest.spyOn(ControlLoopService, 'uploadToscaFile').mockImplementation(() => { + const uploadToscaTemplateSpy = jest.spyOn(ACMService, 'uploadToscaFile').mockImplementation(() => { Promise.resolve({ ok: true, status: 200, diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/DeleteToscaTemplate.js b/gui-clamp/ui-react/src/components/dialogs/ACM/DeleteToscaTemplate.js index c2703cc..3dbf7bd 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/DeleteToscaTemplate.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/DeleteToscaTemplate.js @@ -20,14 +20,14 @@ import React, { useState } from "react"; import Button from "react-bootstrap/Button"; -import ControlLoopService from "../../../api/ControlLoopService"; +import ACMService from "../../../api/ACMService"; const DeleteToscaTemplate = props => { const deleteTemplateHandler = async () => { console.log('deleteTemplateHandler called'); - const response = await ControlLoopService.deleteToscaTemplate(props.templateName, props.templateVersion) + const response = await ACMService.deleteToscaTemplate(props.templateName, props.templateVersion) .catch(error => error.message); if(!response.ok) { diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/DeleteToscaTemplate.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/DeleteToscaTemplate.test.js index c52bdea..c52bdea 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/DeleteToscaTemplate.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/DeleteToscaTemplate.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetLocalToscaFileForUpload.js b/gui-clamp/ui-react/src/components/dialogs/ACM/GetLocalToscaFileForUpload.js index 013dd89..013dd89 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetLocalToscaFileForUpload.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/GetLocalToscaFileForUpload.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetLocalToscaFileForUpload.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/GetLocalToscaFileForUpload.test.js index 9b885c6..9b885c6 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetLocalToscaFileForUpload.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/GetLocalToscaFileForUpload.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetToscaTemplate.js b/gui-clamp/ui-react/src/components/dialogs/ACM/GetToscaTemplate.js index 70c1f41..e86c2cf 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetToscaTemplate.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/GetToscaTemplate.js @@ -19,13 +19,13 @@ import React, { useState } from "react"; import Button from "react-bootstrap/Button"; -import ControlLoopService from "../../../api/ControlLoopService"; +import ACMService from "../../../api/ACMService"; const GetToscaTemplate = (props) => { const getTemplateHandler = async () => { - const response = await ControlLoopService.getToscaTemplate(props.templateName, props.templateVersion) + const response = await ACMService.getToscaTemplate(props.templateName, props.templateVersion) .catch(error => error.message); if(!response.ok) { diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetToscaTemplate.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/GetToscaTemplate.test.js index 71fbeec..71fbeec 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/GetToscaTemplate.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/GetToscaTemplate.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstancePropertiesModal.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstancePropertiesModal.js index 8c8d403..8d0023b 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstancePropertiesModal.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstancePropertiesModal.js @@ -21,7 +21,7 @@ import React, { useEffect, useState } from "react"; import Modal from "react-bootstrap/Modal"; import styled from "styled-components"; import Button from "react-bootstrap/Button"; -import ControlLoopService from "../../../api/ControlLoopService"; +import ACMService from "../../../api/ACMService"; import Alert from "react-bootstrap/Alert"; import * as PropTypes from "prop-types"; import InstantiationUtils from "./utils/InstantiationUtils"; @@ -66,10 +66,10 @@ const InstancePropertiesModal = (props) => { const [instanceName, setInstanceName] = useState('') useEffect(async () => { - const toscaTemplateResponse = await ControlLoopService.getToscaTemplate(templateName, templateVersion) + const toscaTemplateResponse = await ACMService.getToscaTemplate(templateName, templateVersion) .catch(error => error.message); - const toscaInstanceProperties = await ControlLoopService.getCommonOrInstanceProperties(templateName, templateVersion, false) + const toscaInstanceProperties = await ACMService.getCommonOrInstanceProperties(templateName, templateVersion, false) .catch(error => error.message); if (!toscaInstanceProperties.ok) { @@ -111,7 +111,7 @@ const InstancePropertiesModal = (props) => { setToscaFullTemplate(InstantiationUtils.updateTemplate(jsonEditor.getValue(), toscaFullTemplate)); } - const response = await ControlLoopService.createInstanceProperties(instanceName, toscaFullTemplate) + const response = await ACMService.createInstanceProperties(instanceName, toscaFullTemplate) .catch(error => error.message); if (response.ok) { diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstancePropertiesModal.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstancePropertiesModal.test.js index 5c617bf..5c617bf 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstancePropertiesModal.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstancePropertiesModal.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElementItem.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElementItem.js index 0e2c407..0e2c407 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElementItem.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElementItem.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElementItem.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElementItem.test.js index 7b1c1ec..7b1c1ec 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElementItem.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElementItem.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElements.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElements.js index d8e6348..d8e6348 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElements.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElements.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElements.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElements.test.js index 127a886..127a886 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationElements.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationElements.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationItem.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationItem.js index 7b8e453..7b8e453 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationItem.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationItem.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationItem.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationItem.test.js index fe4aaf8..fe4aaf8 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationItem.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationItem.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationManagementModal.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationManagementModal.js index b9db230..78c2685 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationManagementModal.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationManagementModal.js @@ -20,12 +20,12 @@ */ import Modal from "react-bootstrap/Modal"; -import { Alert, Container, Dropdown, Table } from "react-bootstrap"; +import { Alert, Container, Table } from "react-bootstrap"; import Button from "react-bootstrap/Button"; import React, { useEffect, useState } from "react"; import styled from "styled-components"; import { Link } from "react-router-dom"; -import ControlLoopService from "../../../api/ControlLoopService"; +import ACMService from "../../../api/ACMService"; import Row from "react-bootstrap/Row"; import InstantiationUtils from "./utils/InstantiationUtils"; @@ -48,16 +48,17 @@ const DivWhiteSpaceStyled = styled.div` const InstantiationManagementModal = (props) => { const [show, setShow] = useState(true); const [instantiationList, setInstantiationList] = useState([]); - const [deleteInstantiation, setDeleteInstantiation] = useState(false); const [alertMessage, setAlertMessage] = useState(null); useEffect(async () => { - const response = await ControlLoopService.getControlLoopInstantiation(); + const response = await ACMService.getACMInstantiation(); const instantiationListJson = await response.json(); - const parsedInstantiationList = InstantiationUtils.parseInstantiationList(instantiationListJson['controlLoopList']); + console.log(instantiationListJson); + + const parsedInstantiationList = InstantiationUtils.parseInstantiationList(instantiationListJson['automationCompositionList']); setInstantiationList(parsedInstantiationList); }, []); @@ -72,7 +73,6 @@ const InstantiationManagementModal = (props) => { const deleteInstantiationHandler = async (index, instantiation) => { console.log("deleteInstantiationHandler called"); - setDeleteInstantiation(true); console.log(instantiation); @@ -83,13 +83,12 @@ const InstantiationManagementModal = (props) => { const name = instantiation.name; const version = instantiation.version; - const response = await ControlLoopService.deleteInstantiation(name, version); + const response = await ACMService.deleteInstantiation(name, version); updateList(index); if (response.ok) { successAlert(); - setDeleteInstantiation(false); } else { await errorAlert(response); } @@ -147,7 +146,7 @@ const InstantiationManagementModal = (props) => { <Modal.Body> <Container> <Row> - <Link to={ { pathname: "/editControlLoopInstanceProperties" } }> + <Link to={ { pathname: "/editACMInstanceProperties" } }> <Button variant="primary" type="null">Create Instance</Button> </Link> <HorizontalSpace/> @@ -176,7 +175,7 @@ const InstantiationManagementModal = (props) => { <td>{ instantiation.name }</td> <td style={ { textAlign: "center" } }> <Link to={ { - pathname: "editControlLoopInstanceProperties", + pathname: "editACMInstanceProperties", } } state={ instantiation.name }> <Button variant="outline-success" type="null" disabled={ true } diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationManagementModal.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationManagementModal.test.js index d6e33f2..e511ce0 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationManagementModal.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationManagementModal.test.js @@ -25,8 +25,8 @@ import toJson from "enzyme-to-json"; import InstantiationManagementModal from "./InstantiationManagementModal"; import {act} from "react-dom/test-utils"; import {createMemoryHistory} from "history"; -import ControlLoopService from "../../../api/ControlLoopService"; -import clLoopList from "./testFiles/controlLoopList.json"; +import ACMService from "../../../api/ACMService"; +import acmLoopList from "./testFiles/acmList.json"; import {BrowserRouter} from "react-router-dom"; const logSpy = jest.spyOn(console, 'log') @@ -99,14 +99,14 @@ describe('Verify Instantiation Management', () => { it('Check useEffect is being called', async () => { jest.resetAllMocks(); - jest.spyOn(ControlLoopService, 'getControlLoopInstantiation') + jest.spyOn(ACMService, 'getACMInstantiation') .mockImplementationOnce(async () => { return Promise.resolve({ ok: true, status: 200, text: () => "OK", json: () => { - return Promise.resolve(clLoopList); + return Promise.resolve(acmLoopList); } }); }); @@ -138,7 +138,7 @@ describe('Verify Instantiation Management', () => { ok: true, status: 200, text: () => "OK", - json: () => clLoopList + json: () => acmLoopList }) ) diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationOrderStateChangeItem.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationOrderStateChangeItem.js index 8545943..8545943 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationOrderStateChangeItem.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationOrderStateChangeItem.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationOrderStateChangeItem.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationOrderStateChangeItem.test.js index 3981ea5..3981ea5 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/InstantiationOrderStateChangeItem.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/InstantiationOrderStateChangeItem.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/MonitorInstantiation.js b/gui-clamp/ui-react/src/components/dialogs/ACM/MonitorInstantiation.js index 4186477..5699b56 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/MonitorInstantiation.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/MonitorInstantiation.js @@ -22,7 +22,7 @@ import styled from "styled-components"; import Modal from "react-bootstrap/Modal"; import Button from "react-bootstrap/Button"; import InstantiationItem from "./InstantiationItem"; -import ControlLoopService from "../../../api/ControlLoopService"; +import ACMService from "../../../api/ACMService"; import InstantiationElements from "./InstantiationElements"; import { Alert } from "react-bootstrap"; @@ -35,21 +35,21 @@ const AlertStyled = styled(Alert)` const MonitorInstantiation = (props) => { const [show, setShow] = useState(true); - const [controlLoopList, setControlLoopList] = useState([]); - const [controlLoopInstantiationOk, setControlLoopInstantiationOk] = useState(true); - const [controlLoopInstantiationError, setControlLoopInstantiationError] = useState({}); + const [acmList, setAcmList] = useState([]); + const [acmInstantiationOk, setAcmInstantiationOk] = useState(true); + const [acmInstantiationError, setACMInstantiationError] = useState({}); useEffect(async () => { - const controlLoopInstantiation = await ControlLoopService.getControlLoopInstantiation() + const acmInstantiation = await ACMService.getACMInstantiation() .catch(error => error.message); - const controlLoopInstantiationJson = await controlLoopInstantiation.json(); + const acmInstantiationJson = await acmInstantiation.json(); - if (!controlLoopInstantiation.ok || controlLoopInstantiationJson['controlLoopList'].length === 0) { - setControlLoopInstantiationOk(false) - setControlLoopInstantiationError(controlLoopInstantiationJson) + if (!acmInstantiation.ok || acmInstantiationJson['automationCompositionList'].length === 0) { + setAcmInstantiationOk(false) + setACMInstantiationError(acmInstantiationJson) } else { - setControlLoopList(controlLoopInstantiationJson['controlLoopList']); + setAcmList(acmInstantiationJson['automationCompositionList']); } }, []) @@ -66,14 +66,14 @@ const MonitorInstantiation = (props) => { </Modal.Header> <Modal.Body> { - controlLoopList.map((clList, index) => ( + acmList.map((clList, index) => ( <InstantiationItem title={ clList["name"] } orderedState={ clList["orderedState"] } index={ index } key={ index } > <InstantiationElements elements={ clList["elements"] } /> </InstantiationItem> )) } - <AlertStyled show={ !controlLoopInstantiationOk } - variant="danger">Can't get control loop instantiation info:<br/>{ JSON.stringify(controlLoopInstantiationError, null, 2) }</AlertStyled> + <AlertStyled show={ !acmInstantiationOk } + variant="danger">Can't get acm instantiation info:<br/>{ JSON.stringify(acmInstantiationError, null, 2) }</AlertStyled> </Modal.Body> <Modal.Footer> <Button variant="secondary" type="null" onClick={ handleClose }>Close</Button> diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/MonitorInstantiation.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/MonitorInstantiation.test.js index 9bc8c04..5923f10 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/MonitorInstantiation.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/MonitorInstantiation.test.js @@ -23,8 +23,8 @@ import toJson from "enzyme-to-json"; import { act } from "react-dom/test-utils"; import { createMemoryHistory } from "history"; import MonitorInstantiation from "./MonitorInstantiation"; -import ControlLoopService from "../../../api/ControlLoopService"; -import clLoopList from "./testFiles/controlLoopList.json"; +import ACMService from "../../../api/ACMService"; +import clLoopList from "./testFiles/acmList.json"; const logSpy = jest.spyOn(console, 'log') const history = createMemoryHistory(); @@ -68,7 +68,7 @@ describe('Verify MonitorInstantiation', () => { it('Check useEffect is being called', async () => { jest.resetAllMocks(); - jest.spyOn(ControlLoopService, 'getControlLoopInstantiation') + jest.spyOn(ACMService, 'getACMInstantiation') .mockImplementationOnce(async () => { return Promise.resolve({ ok: true, diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/ReadAndConvertYaml.js b/gui-clamp/ui-react/src/components/dialogs/ACM/ReadAndConvertYaml.js index 5fc97c4..5fc97c4 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/ReadAndConvertYaml.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/ReadAndConvertYaml.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/ReadAndConvertYaml.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/ReadAndConvertYaml.test.js index 03192a1..03192a1 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/ReadAndConvertYaml.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/ReadAndConvertYaml.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/UploadToscaFile.js b/gui-clamp/ui-react/src/components/dialogs/ACM/UploadToscaFile.js index 380838e..4357a9f 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/UploadToscaFile.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/UploadToscaFile.js @@ -19,7 +19,7 @@ import Button from "react-bootstrap/Button"; import React, { useState } from "react"; -import ControlLoopService from "../../../api/ControlLoopService"; +import ACMService from "../../../api/ACMService"; const UploadToscaFile = (props) => { @@ -27,7 +27,7 @@ const UploadToscaFile = (props) => { event.preventDefault(); console.log('postServiceTemplateHandler called'); - const response = await ControlLoopService.uploadToscaFile(props.toscaObject) + const response = await ACMService.uploadToscaFile(props.toscaObject) .catch(error => error.message); // const responseMessage = await response.text(); diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/UploadToscaFile.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/UploadToscaFile.test.js index 520eea9..520eea9 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/UploadToscaFile.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/UploadToscaFile.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/AccordionHeader.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/AccordionHeader.test.js.snap index da86eb7..da86eb7 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/AccordionHeader.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/AccordionHeader.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/ChangeOrderStateModal.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/ChangeOrderStateModal.test.js.snap index 478b886..478b886 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/ChangeOrderStateModal.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/ChangeOrderStateModal.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/CommissioningModal.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/CommissioningModal.test.js.snap index 5ed3f3e..4ff976a 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/CommissioningModal.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/CommissioningModal.test.js.snap @@ -13,7 +13,7 @@ exports[`Verify CommissioningModal renders correctly 1`] = ` closeLabel="Close" > <ModalTitle> - Change Control Loop Common Properties + Change ACM Common Properties </ModalTitle> </ModalHeader> <br /> diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/DeleteToscaTemplate.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/DeleteToscaTemplate.test.js.snap index cd2288e..cd2288e 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/DeleteToscaTemplate.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/DeleteToscaTemplate.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/GetLocalToscaFileForUpload.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/GetLocalToscaFileForUpload.test.js.snap index 84168fd..84168fd 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/GetLocalToscaFileForUpload.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/GetLocalToscaFileForUpload.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/GetToscaTemplate.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/GetToscaTemplate.test.js.snap index 873afa7..873afa7 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/GetToscaTemplate.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/GetToscaTemplate.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstancePropertiesModal.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstancePropertiesModal.test.js.snap index d655b08..d655b08 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstancePropertiesModal.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstancePropertiesModal.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationElementItem.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationElementItem.test.js.snap index 81f5f26..81f5f26 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationElementItem.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationElementItem.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationElements.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationElements.test.js.snap index 8fa928e..8fa928e 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationElements.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationElements.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationItem.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationItem.test.js.snap index a3a230a..a3a230a 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationItem.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationItem.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationManagementModal.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationManagementModal.test.js.snap index 21a8dd5..b800f52 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationManagementModal.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationManagementModal.test.js.snap @@ -26,7 +26,7 @@ exports[`Verify Instantiation Management renders correctly 1`] = ` <Link to={ Object { - "pathname": "/editControlLoopInstanceProperties", + "pathname": "/editACMInstanceProperties", } } > diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationOrderStateChangeItem.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationOrderStateChangeItem.test.js.snap index bbf92ca..bbf92ca 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/InstantiationOrderStateChangeItem.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/InstantiationOrderStateChangeItem.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/MonitorInstantiation.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/MonitorInstantiation.test.js.snap index ad1f7f1..2b07252 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/MonitorInstantiation.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/MonitorInstantiation.test.js.snap @@ -21,7 +21,7 @@ exports[`Verify MonitorInstantiation renders correctly 1`] = ` show={false} variant="danger" > - Can't get control loop instantiation info: + Can't get acm instantiation info: <br /> {} </Styled(Alert)> diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/ReadAndConvertYaml.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/ReadAndConvertYaml.test.js.snap index 76739f3..76739f3 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/ReadAndConvertYaml.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/ReadAndConvertYaml.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/UploadToscaFile.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/UploadToscaFile.test.js.snap index a1ae439..a1ae439 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/__snapshots__/UploadToscaFile.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/__snapshots__/UploadToscaFile.test.js.snap diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/controlLoopList.json b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/acmList.json index d549879..f854d90 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/controlLoopList.json +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/acmList.json @@ -1,5 +1,5 @@ { - "controlLoopList": [ + "automationCompositionList": [ { "name": "PMSHInstance0", "version": "1.0.1", diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/commonProps.json b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/commonProps.json index 71f98f8..71f98f8 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/commonProps.json +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/commonProps.json diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/fullTemplate.json b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/fullTemplate.json index 8b77554..8b77554 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/fullTemplate.json +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/fullTemplate.json diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/instanceProps.json b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/instanceProps.json index b8250fd..b8250fd 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/instanceProps.json +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/instanceProps.json diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/jsonEditorData.json b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/jsonEditorData.json index c09424f..c09424f 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/jsonEditorData.json +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/jsonEditorData.json diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/orderedStateJson.json b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/orderedStateJson.json index 91c892d..1179fce 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/testFiles/orderedStateJson.json +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/testFiles/orderedStateJson.json @@ -1,6 +1,6 @@ { "orderedState": "PASSIVE", - "controlLoopIdentifierList": [ + "acmIdentifierList": [ { "name": "PMSH_Instance1", "version": "2.3.1" diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/CommissioningUtils.js b/gui-clamp/ui-react/src/components/dialogs/ACM/utils/CommissioningUtils.js index 2d98598..2d98598 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/CommissioningUtils.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/utils/CommissioningUtils.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/CommissioningUtils.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/utils/CommissioningUtils.test.js index 8304ecb..8304ecb 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/CommissioningUtils.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/utils/CommissioningUtils.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/InstantiationUtils.js b/gui-clamp/ui-react/src/components/dialogs/ACM/utils/InstantiationUtils.js index fd83432..aaaa1bd 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/InstantiationUtils.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/utils/InstantiationUtils.js @@ -23,12 +23,13 @@ import { JSONEditor } from "@json-editor/json-editor"; const InstantiationUtils = { - parseInstantiationList: (controlLoopList) => { - const parsedControlLoopList = []; + parseInstantiationList: (acmList) => { + console.log(acmList); + const parsedAcmList = []; - controlLoopList.map((instance, index) => { + acmList.map((instance, index) => { - const controlLoopObj = { + const acmObj = { index, name: instance['name'], version: instance['version'], @@ -37,10 +38,10 @@ const InstantiationUtils = { disableDelete: instance['state'] !== 'UNINITIALISED' } - parsedControlLoopList.push(controlLoopObj); + parsedAcmList.push(acmObj); }); - return parsedControlLoopList; + return parsedAcmList; }, makeSchemaForInstanceProperties: (instanceProps) => { diff --git a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/InstantiationUtils.test.js b/gui-clamp/ui-react/src/components/dialogs/ACM/utils/InstantiationUtils.test.js index 4077ff8..4077ff8 100644 --- a/gui-clamp/ui-react/src/components/dialogs/ControlLoop/utils/InstantiationUtils.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/ACM/utils/InstantiationUtils.test.js diff --git a/gui-clamp/ui-react/src/components/dialogs/InstantiationManagementModal.test.js b/gui-clamp/ui-react/src/components/dialogs/InstantiationManagementModal.test.js deleted file mode 100644 index 25292d0..0000000 --- a/gui-clamp/ui-react/src/components/dialogs/InstantiationManagementModal.test.js +++ /dev/null @@ -1,69 +0,0 @@ -/* - * ============LICENSE_START======================================================= - * Copyright (C) 2021 Nordix Foundation. - * ================================================================================ - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * SPDX-License-Identifier: Apache-2.0 - * ============LICENSE_END========================================================= - */ - -import { mount, shallow } from "enzyme"; -import React from "react"; -import toJson from "enzyme-to-json"; -import { createMemoryHistory } from "history"; -import { act } from "react-dom/test-utils"; -import ChangeOrderStateModal from "./ControlLoop/ChangeOrderStateModal"; - -describe('Verify InstantiationManagementModal', () => { - - it("renders without crashing", () => { - shallow(<ChangeOrderStateModal />); - }); - - it("renders correctly", () => { - const tree = shallow(<ChangeOrderStateModal />); - expect(toJson(tree)).toMatchSnapshot(); - }); - - it('should have save button element', () => { - const container = shallow(<ChangeOrderStateModal/>) - expect(container.find('[variant="primary"]').length).toEqual(1); - }); - - it('handleSave called when save button clicked', () => { - const history = createMemoryHistory(); - const component = mount(<ChangeOrderStateModal history={ history }/>) - const logSpy = jest.spyOn(console, 'log'); - - act(() => { - component.find('[variant="primary"]').simulate('click'); - expect(logSpy).toHaveBeenCalledWith('handleSave called'); - }); - }); - - it('should have close button element', () => { - const container = shallow(<ChangeOrderStateModal/>) - expect(container.find('[variant="secondary"]').length).toEqual(1); - }); - - it('handleClose called when close button clicked', () => { - const history = createMemoryHistory(); - const component = mount(<ChangeOrderStateModal history={ history }/>) - const logSpy = jest.spyOn(console, 'log'); - - act(() => { - component.find('[variant="secondary"]').simulate('click'); - expect(logSpy).toHaveBeenCalledWith('handleClose called'); - }); - }); -}); diff --git a/gui-clamp/ui-react/src/components/dialogs/PerformActions.js b/gui-clamp/ui-react/src/components/dialogs/PerformActions.js index ba7c99d..428902e 100644 --- a/gui-clamp/ui-react/src/components/dialogs/PerformActions.js +++ b/gui-clamp/ui-react/src/components/dialogs/PerformActions.js @@ -47,7 +47,7 @@ export default class PerformActions extends React.Component { const loopName = this.state.loopName; if (action === 'delete') { - if (window.confirm('You are about to remove Control Loop Model "' + loopName + + if (window.confirm('You are about to remove ACM Model "' + loopName + '". Select OK to continue with deletion or Cancel to keep the model.') === false) { return; } diff --git a/gui-clamp/ui-react/src/components/dialogs/Policy/PolicyEditor.test.js b/gui-clamp/ui-react/src/components/dialogs/Policy/PolicyEditor.test.js index 5e63ab4..339d660 100644 --- a/gui-clamp/ui-react/src/components/dialogs/Policy/PolicyEditor.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/Policy/PolicyEditor.test.js @@ -49,7 +49,7 @@ describe('Verify PolicyEditor', () => { ], "eventName": "vLoadBalancer", "policyVersion": "v0.0.1", - "controlLoopSchemaType": "VM", + "acmSchemaType": "VM", "policyName": "DCAE.Config_tca-hi-lo" } ] diff --git a/gui-clamp/ui-react/src/components/dialogs/Policy/PolicyModal.test.js b/gui-clamp/ui-react/src/components/dialogs/Policy/PolicyModal.test.js index 658b19e..2cb1af5 100644 --- a/gui-clamp/ui-react/src/components/dialogs/Policy/PolicyModal.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/Policy/PolicyModal.test.js @@ -45,7 +45,7 @@ describe('Verify PolicyModal', () => { "name": "OPERATIONAL_h2NMX_v1_0_ResourceInstanceName1_tca", "configurationsJson": { "operational_policy": { - "controlLoop": {}, + "acm": {}, "policies": [] } }, diff --git a/gui-clamp/ui-react/src/components/dialogs/Policy/ToscaViewer.test.js b/gui-clamp/ui-react/src/components/dialogs/Policy/ToscaViewer.test.js index 5b59760..538f0a8 100644 --- a/gui-clamp/ui-react/src/components/dialogs/Policy/ToscaViewer.test.js +++ b/gui-clamp/ui-react/src/components/dialogs/Policy/ToscaViewer.test.js @@ -31,7 +31,7 @@ describe('Verify ToscaViewer', () => { let toscaYaml = fs.readFileSync('src/components/dialogs/Policy/toscaData.test.yaml', { encoding: 'utf8', flag: 'r' }) const toscaData = { - "policyModelType": "onap.policies.controlloop.Guard", + "policyModelType": "onap.policies.acm.Guard", "version": "1.0.0", "policyAcronym": "Guard", "createdDate": "2021-04-09T02:29:31.407356Z", diff --git a/gui-clamp/ui-react/src/components/dialogs/Policy/__snapshots__/PolicyEditor.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/Policy/__snapshots__/PolicyEditor.test.js.snap index ea40bfd..ea435fc 100644 --- a/gui-clamp/ui-react/src/components/dialogs/Policy/__snapshots__/PolicyEditor.test.js.snap +++ b/gui-clamp/ui-react/src/components/dialogs/Policy/__snapshots__/PolicyEditor.test.js.snap @@ -12,7 +12,7 @@ exports[`Verify PolicyEditor Test the render method 1`] = ` "domain": "measurementsForVfScaling", "metricsPerEventName": Array [ Object { - "controlLoopSchemaType": "VM", + "acmSchemaType": "VM", "eventName": "vLoadBalancer", "policyName": "DCAE.Config_tca-hi-lo", "policyScope": "DCAE", diff --git a/gui-clamp/ui-react/src/components/dialogs/Policy/toscaInstantiationData.test.json b/gui-clamp/ui-react/src/components/dialogs/Policy/toscaInstantiationData.test.json index d740203..176d921 100644 --- a/gui-clamp/ui-react/src/components/dialogs/Policy/toscaInstantiationData.test.json +++ b/gui-clamp/ui-react/src/components/dialogs/Policy/toscaInstantiationData.test.json @@ -1,5 +1,5 @@ { - "controlLoopList": [ + "acmList": [ { "name": "PMSHInstance0", "version": "1.0.1", diff --git a/gui-clamp/ui-react/src/components/dialogs/__snapshots__/InstantiationManagementModal.test.js.snap b/gui-clamp/ui-react/src/components/dialogs/__snapshots__/InstantiationManagementModal.test.js.snap deleted file mode 100644 index fde9ba1..0000000 --- a/gui-clamp/ui-react/src/components/dialogs/__snapshots__/InstantiationManagementModal.test.js.snap +++ /dev/null @@ -1,114 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`Verify InstantiationManagementModal renders correctly 1`] = ` -<Styled(Modal) - backdrop="static" - keyboard={false} - onHide={[Function]} - show={true} - size="sm" -> - <ModalHeader - closeButton={true} - closeLabel="Close" - > - <ModalTitle> - Manage Instantiation - </ModalTitle> - </ModalHeader> - <div - style={ - Object { - "padding": "5px 5px 0 5px", - } - } - > - <ModalBody> - <Container - fluid={false} - > - <Dropdown - navbar={false} - onSelect={[Function]} - > - <DropdownToggle - id="dropdown-basic" - variant="dark" - > - Select Order State - </DropdownToggle> - <DropdownMenu - align="left" - alignRight={false} - flip={true} - > - <DropdownItem - as={ - Object { - "$$typeof": Symbol(react.forward_ref), - "render": [Function], - } - } - disabled={false} - eventKey="UNINITIALISED" - > - UNINITIALISED - </DropdownItem> - <DropdownItem - as={ - Object { - "$$typeof": Symbol(react.forward_ref), - "render": [Function], - } - } - disabled={false} - eventKey="PASSIVE" - > - PASSIVE - </DropdownItem> - <DropdownItem - as={ - Object { - "$$typeof": Symbol(react.forward_ref), - "render": [Function], - } - } - disabled={false} - eventKey="RUNNING" - > - RUNNING - </DropdownItem> - </DropdownMenu> - </Dropdown> - </Container> - <Styled(Alert) - show={false} - variant="danger" - > - Can't get instantiation ordered state: - <br /> - {} - </Styled(Alert)> - </ModalBody> - <styled.div /> - </div> - <ModalFooter> - <Button - active={false} - disabled={false} - onClick={[Function]} - variant="primary" - > - Save - </Button> - <Button - active={false} - disabled={false} - onClick={[Function]} - variant="secondary" - > - Close - </Button> - </ModalFooter> -</Styled(Modal)> -`; |