aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/resources/META-INF
diff options
context:
space:
mode:
authorxg353y <xg353y@intl.att.com>2019-03-12 13:07:46 +0100
committerxg353y <xg353y@intl.att.com>2019-03-13 11:59:04 +0100
commit4549fd92024cdadf3277d7cc364f33109ca22b59 (patch)
tree68a65abd2b9f6bba6235c8cee3515660539cedaa /src/main/resources/META-INF
parent6adb590f29c9f2ccd3270fc10334c1c0859d92e7 (diff)
Add UI tests
Add test cases for propertyController.js Issue-ID: CLAMP-310 Change-Id: I7ae2cc425d9a7343791bae9ab7704e09389f270a Signed-off-by: xg353y <xg353y@intl.att.com>
Diffstat (limited to 'src/main/resources/META-INF')
-rw-r--r--src/main/resources/META-INF/resources/designer/scripts/propertyController.js19
1 files changed, 10 insertions, 9 deletions
diff --git a/src/main/resources/META-INF/resources/designer/scripts/propertyController.js b/src/main/resources/META-INF/resources/designer/scripts/propertyController.js
index d47956507..c3f1aaf13 100644
--- a/src/main/resources/META-INF/resources/designer/scripts/propertyController.js
+++ b/src/main/resources/META-INF/resources/designer/scripts/propertyController.js
@@ -20,9 +20,9 @@
* ===================================================================
*
*/
- function saveMsProperties(type, form) {
+
+function saveMsProperties(type, form) {
var newMsProperties = cl_props["microServicePolicies"];
-
for (p in newMsProperties) {
if (newMsProperties[p]["name"] == type) {
newMsProperties[p]["properties"] = form;
@@ -40,9 +40,9 @@
def.resolve(data);
}).error(function(data) {
def.reject("Save Model not successful");
- return def.promise;
- };
+ });
cl_props["microServicePolicies"] = newMsProperties;
+ return def.promise;
}
function saveGlobalProperties(form) {
@@ -57,9 +57,9 @@ function saveGlobalProperties(form) {
def.resolve(data);
}).error(function(data) {
def.reject("Save Model not successful");
- return def.promise;
- };
+ });
cl_props["globalPropertiesJson"] = form;
+ return def.promise;
}
function saveOpPolicyProperties(form) {
@@ -77,10 +77,10 @@ function saveOpPolicyProperties(form) {
def.resolve(data);
}).error(function(data) {
def.reject("Save Model not successful");
- return def.promise;
- };
+ });
- cl_props["operationalPolicies"] = newOpProperties;
+ cl_props["operationalPolicies"] = newOpProperties;
+ return def.promise;
}
function getOperationalPolicyProperty() {
@@ -122,3 +122,4 @@ function getDeploymentID() {
function getDeploymentStatusURL() {
return cl_props["dcaeDeploymentStatusUrl"];
}
+module.exports = { getOperationalPolicyProperty,getGlobalProperty,getMsProperty,getMsUI,getStatus,getDeploymentID,getDeploymentStatusURL }; \ No newline at end of file