aboutsummaryrefslogtreecommitdiffstats
path: root/gui-clamp/ui-react/src/api/ControlLoopService.js
diff options
context:
space:
mode:
authorsaul.gill <saul.gill@est.tech>2021-10-29 14:24:20 +0100
committersaul.gill <saul.gill@est.tech>2021-10-29 15:16:06 +0100
commitce0db169bce5d44ab36be7015a11c9a0205e05a1 (patch)
treec2b631c8e320c1528fe4b87da9d5a21eeabe41e8 /gui-clamp/ui-react/src/api/ControlLoopService.js
parent6df019389c1f5de9dd5b7601e270f0ef17ea2491 (diff)
Added tests to improve coverage
Added new tests and snapshots Altered existing tests to bring up coverage Altered package.json in response to warning messages Removed unused functions from ControlLoopService Added json testFiles Added utils directory for out-of-component functions Issue-ID: POLICY-3643 Change-Id: I3405a4421637e63235ff5176c913a5a5f9a4a44c Signed-off-by: saul.gill <saul.gill@est.tech>
Diffstat (limited to 'gui-clamp/ui-react/src/api/ControlLoopService.js')
-rw-r--r--gui-clamp/ui-react/src/api/ControlLoopService.js33
1 files changed, 0 insertions, 33 deletions
diff --git a/gui-clamp/ui-react/src/api/ControlLoopService.js b/gui-clamp/ui-react/src/api/ControlLoopService.js
index b3d987c..011d5ae 100644
--- a/gui-clamp/ui-react/src/api/ControlLoopService.js
+++ b/gui-clamp/ui-react/src/api/ControlLoopService.js
@@ -132,18 +132,6 @@ export default class ControlLoopService {
return data;
}
- static async getToscaControlLoopDefinitions() {
-
- const response = await fetch(window.location.pathname +
- 'restservices/clds/v2/toscaControlLoop/getElementDefinitions');
-
- this.checkResponseForError(response);
-
- const data = await response;
-
- return data;
- }
-
static async getCommonOrInstanceProperties(name, version, isCommon) {
const params = {
name: name,
@@ -157,25 +145,4 @@ export default class ControlLoopService {
return response;
}
- static async getToscaServiceTemplateSchema(section) {
-
- const params = {
- section: section
- }
-
- const response = await fetch(window.location.pathname +
- 'restservices/clds/v2/toscaControlLoop/getJsonSchema' + '?' + (new URLSearchParams(params)));
-
- this.checkResponseForError(response);
-
- return response;
- }
-
- static checkResponseForError(response) {
- if (!response.ok) {
- const message = `An error has occurred: ${ response.status }`;
- throw new Error(message);
- }
- }
-
}