summaryrefslogtreecommitdiffstats
path: root/test-apis-ci/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'test-apis-ci/src/main')
-rw-r--r--test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/execute/devCI/AndreyTest.java2
-rw-r--r--test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/validation/AuditValidationUtils.java3
-rw-r--r--test-apis-ci/src/main/java/org/openecomp/sdc/externalApis/CRUDExternalAPI.java10
-rw-r--r--test-apis-ci/src/main/java/org/openecomp/sdc/externalApis/VFCMTExternalAPI.java4
-rw-r--r--test-apis-ci/src/main/resources/ci/scripts/copyToStorage.sh13
5 files changed, 17 insertions, 15 deletions
diff --git a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/execute/devCI/AndreyTest.java b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/execute/devCI/AndreyTest.java
index 45c6b18b59..bbd05c893e 100644
--- a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/execute/devCI/AndreyTest.java
+++ b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/execute/devCI/AndreyTest.java
@@ -55,7 +55,7 @@ public class AndreyTest {
// File path = new File("C:/Data/D2.0/TOSCA_Ex/resource-Vl11Vl10-template.yml");
// File path = new File("C:/Data/D2.0/TOSCA_Ex/service-Servicepxtc-template US822998.yml");
// File path = new File("C:/Data/FileToParse/Definitions/service-Ciservice513e6fa67d07-template.yml");
- toscaDefinition = ToscaParserUtils.parseToscaMainYamlToJavaObjectByCsarLocation(new File("C:/Data/FileToParse/LDSA/LDSA_amdocs.csar"));
+ toscaDefinition = ToscaParserUtils.parseToscaMainYamlToJavaObjectByCsarLocation(new File("C:/Data/FileToParse/LDSA/service-LdsaService-csar.csar"));
// File path = new File("C:/Data/FileToParse/Definitions/resource-Civfonboarded2016006VvmVvm301607E2100a9b04-template.yml");
// File csarPath = new File("C:/Data/D2.0/TOSCA_Ex/Nested.csar");
diff --git a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/validation/AuditValidationUtils.java b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/validation/AuditValidationUtils.java
index f4d9fe3f35..12f7ea327a 100644
--- a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/validation/AuditValidationUtils.java
+++ b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/validation/AuditValidationUtils.java
@@ -659,8 +659,7 @@ public class AuditValidationUtils {
public static void compareElements(Object expectedValue, Object foundValue) {
if (expectedValue instanceof String) {
assertTrue("Actual value " + foundValue + " is not string", foundValue instanceof String);
- assertTrue("Expected " + expectedValue + " not equal to actual " + foundValue,
- foundValue.equals(expectedValue));
+ assertTrue("Expected " + "[" + expectedValue +"]" + " not equal to actual [" + foundValue + "]", foundValue.equals(expectedValue));
}
/*
* else if( expectedValue instanceof Number){ assertTrue(foundValue
diff --git a/test-apis-ci/src/main/java/org/openecomp/sdc/externalApis/CRUDExternalAPI.java b/test-apis-ci/src/main/java/org/openecomp/sdc/externalApis/CRUDExternalAPI.java
index 127ae54784..668508751b 100644
--- a/test-apis-ci/src/main/java/org/openecomp/sdc/externalApis/CRUDExternalAPI.java
+++ b/test-apis-ci/src/main/java/org/openecomp/sdc/externalApis/CRUDExternalAPI.java
@@ -89,6 +89,7 @@ import org.openecomp.sdc.common.api.Constants;
import org.openecomp.sdc.common.config.EcompErrorName;
import org.openecomp.sdc.common.datastructure.AuditingFieldsKeysEnum;
import org.openecomp.sdc.common.util.GeneralUtility;
+import org.openecomp.sdc.common.util.ValidationUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.testng.Assert;
@@ -2098,7 +2099,7 @@ public class CRUDExternalAPI extends ComponentBaseTest {
ErrorInfo errorInfo = ErrorValidationUtils.parseErrorConfigYaml(ActionStatus.ARTIFACT_LOGICAL_NAME_CANNOT_BE_CHANGED.name());
List<String> variables = asList();
- artifactReqDetails.setArtifactLabel("invalGGfdsiofhdsouhfoidshfoidshoifhsdoifhdsouihfdsofhiufdsghiufghodhfioudsgafodsgaiofudsghifudsiugfhiufawsouipfhgawseiupfsadiughdfsoiuhgfaighfpasdghfdsaqgfdsgdfgidType");
+ artifactReqDetails.setArtifactLabel("invalGGfdsiofhdsouhfoidshfoidshoifhsdoifhdsouihfdsofhiufdsghiufghodhfioudsgafodsgaiofudsghifudsiugfhiufawsouipfhgawseiupfsadiughdfsoiuhgfaighfpasdghfdsaqgfdsgdfgidTypeinvalGGfdsiofhdsouhfoidshfoidshoifhsdoifhdsouihfdsofhiufdsghiufghodhfioudsgafodsgaiofudsghifudsiugfhiufawsouipfhgawseiupfsadiughdfsoiuhgfaighfpasdghfdsaqgfdsgdfgidType");
if(componentInstance != null) {
updateArtifactOfAssetIncludingValiditionOfAuditAndResponseCode(component, ElementFactory.getDefaultUser(UserRoleEnum.DESIGNER),
@@ -2166,8 +2167,8 @@ public class CRUDExternalAPI extends ComponentBaseTest {
}
}
- ErrorInfo errorInfo = ErrorValidationUtils.parseErrorConfigYaml(ActionStatus.ARTIFACT_LOGICAL_NAME_CANNOT_BE_CHANGED.name());
- List<String> variables = asList();
+ ErrorInfo errorInfo = ErrorValidationUtils.parseErrorConfigYaml(ActionStatus.EXCEEDS_LIMIT.name());
+ List<String> variables = asList("artifact description", ValidationUtils.ARTIFACT_DESCRIPTION_MAX_LENGTH.toString());
artifactReqDetails.setDescription("invalGGfdsiofhdsouhfoidshfoidshoifhsdoifhdsouihfdsofhiufdsinvalGGfdsiofhdsouhfoidshfoidshoifhsdoifhdsouihfdsofhiufdsghiufghodhfioudsgafodsgaiofudsghifudsiugfhiufawsouipfhgawseiupfsadiughdfsoiuhgfaighfpasdghfdsaqgfdsgdfgidTypeinvalGGfdsiofhdsouhfoidshfoidshoifhsdoifhdsouihfdsofhiufdsghiufghodhfioudsgafodsgaiofudsghifudsiugfhiufawsouipfhgawseiupfsadiughdfsoiuhgfaighfpasdghfdsaqgfdsgdfgidTypeghiufghodhfioudsgafodsgaiofudsghifudsiugfhiufawsouipfhgawseiupfsadiughdfsoiuhgfaighfpasdghfdsaqgfdsgdfgidType");
if(componentInstance != null) {
@@ -2202,7 +2203,8 @@ public class CRUDExternalAPI extends ComponentBaseTest {
}
- ErrorInfo errorInfo = ErrorValidationUtils.parseErrorConfigYaml(ActionStatus.ARTIFACT_LOGICAL_NAME_CANNOT_BE_CHANGED.name());
+// ErrorInfo errorInfo = ErrorValidationUtils.parseErrorConfigYaml(ActionStatus.ARTIFACT_LOGICAL_NAME_CANNOT_BE_CHANGED.name());
+ ErrorInfo errorInfo = ErrorValidationUtils.parseErrorConfigYaml(ActionStatus.MISSING_DATA.name());
List<String> variables = asList("artifact description");
artifactReqDetails.setDescription("");
diff --git a/test-apis-ci/src/main/java/org/openecomp/sdc/externalApis/VFCMTExternalAPI.java b/test-apis-ci/src/main/java/org/openecomp/sdc/externalApis/VFCMTExternalAPI.java
index 6e212d3155..a97c8e7336 100644
--- a/test-apis-ci/src/main/java/org/openecomp/sdc/externalApis/VFCMTExternalAPI.java
+++ b/test-apis-ci/src/main/java/org/openecomp/sdc/externalApis/VFCMTExternalAPI.java
@@ -216,10 +216,6 @@ public class VFCMTExternalAPI extends ComponentBaseTest {
// Various failure flows
@Test(dataProvider="createVfcmtVariousFailureFlows")
public void createVfcmtVariousFailureFlows(String flow) throws Exception {
- //TODO: check what happens now, test will prbably fail
- if(flow.equals("resource_type_missing") || flow.equals("resource_type_invalid")) {
- throw new SkipException("TC require repairs");
- }
User defaultUser = ElementFactory.getDefaultUser(UserRoleEnum.DESIGNER);
ResourceExternalReqDetails defaultResource = ElementFactory.getDefaultResourceByType("ci", ResourceCategoryEnum.TEMPLATE_MONITORING_TEMPLATE, defaultUser.getUserId(), ResourceTypeEnum.VFCMT.toString());
diff --git a/test-apis-ci/src/main/resources/ci/scripts/copyToStorage.sh b/test-apis-ci/src/main/resources/ci/scripts/copyToStorage.sh
index 30094fe235..b7b8c09715 100644
--- a/test-apis-ci/src/main/resources/ci/scripts/copyToStorage.sh
+++ b/test-apis-ci/src/main/resources/ci/scripts/copyToStorage.sh
@@ -3,7 +3,6 @@
REPORT_NAME=$1
VERSION=$2
ENV=$3
-IP=$4
if [ -z "$REPORT_NAME" ]
then
@@ -19,6 +18,12 @@ if [ -z "$REPORT_NAME" ]
fi
fi
+
+source conf/attInternal.info
+IP=$automationResutlsRepo
+PASS=$automationResutlsRepoPass
+
+echo ${IP}
/usr/bin/expect << EOF
spawn ssh admin@${IP} mkdir -p -m 775 /home/admin/reports/${ENV}/${VERSION}/APIs/
@@ -29,7 +34,7 @@ expect {
exp_continue
}
-re ".*sword.*" {
- exp_send "Aa123456\r"
+ exp_send ${PASS}\r
}
}
@@ -43,7 +48,7 @@ expect {
exp_continue
}
-re ".*sword.*" {
- exp_send "Aa123456\r"
+ exp_send ${PASS}\r
}
}
@@ -57,7 +62,7 @@ expect {
exp_continue
}
-re ".*sword.*" {
- exp_send "Aa123456\r"
+ exp_send ${PASS}\r
}
}