diff --git a/pom.xml b/pom.xml
index 58c1d160..327089ae 100644
--- a/pom.xml
+++ b/pom.xml
@@ -48,14 +48,39 @@
- saucelabs-repository
- https://repository-saucelabs.forge.cloudbees.com/release
+ wso2.releases
+ WSO2 Releases Repository
+ https://maven.wso2.org/nexus/content/repositories/releases/
true
+ daily
+ ignore
+
+
+
+
+ wso2.snapshots
+ WSO2 Snapshot Repository
+ https://maven.wso2.org/nexus/content/repositories/snapshots/
true
+ daily
+
+ false
+
+
+
+
+ wso2-nexus
+ WSO2 internal Repository
+ https://maven.wso2.org/nexus/content/groups/wso2-public/
+
+ true
+ daily
+ ignore
+
@@ -386,8 +411,8 @@
1.6.1-wso2v37
- 6.1.1
- 0.7.5.201505241946
+ 7.10.1
+ 0.8.12
3.0.22
3.2.1
1.2.3
diff --git a/test-automation-framework/org.wso2.carbon.automation.engine/pom.xml b/test-automation-framework/org.wso2.carbon.automation.engine/pom.xml
index f920316c..f18e8446 100644
--- a/test-automation-framework/org.wso2.carbon.automation.engine/pom.xml
+++ b/test-automation-framework/org.wso2.carbon.automation.engine/pom.xml
@@ -38,7 +38,7 @@
org.jacoco
jacoco-maven-plugin
- 0.7.1.201405082137
+ ${jacoco.core.version}
default-prepare-agent
@@ -58,7 +58,7 @@
org.apache.maven.plugins
maven-surefire-plugin
- 2.17
+ 3.2.5
default-test
@@ -72,7 +72,7 @@
1
true
- -javaagent:${settings.localRepository}/org/jacoco/org.jacoco.agent/0.7.1.201405082137/org.jacoco.agent-0.7.1.201405082137-runtime.jar=destfile=${project.build.directory}/jacoco.exec
+ -javaagent:${settings.localRepository}/org/jacoco/org.jacoco.agent/${jacoco.core.version}/org.jacoco.agent-${jacoco.core.version}-runtime.jar=destfile=${project.build.directory}/jacoco.exec
src/test/resources/testng.xml
diff --git a/test-automation-framework/org.wso2.carbon.automation.engine/src/main/java/org/wso2/carbon/automation/engine/frameworkutils/CodeCoverageUtils.java b/test-automation-framework/org.wso2.carbon.automation.engine/src/main/java/org/wso2/carbon/automation/engine/frameworkutils/CodeCoverageUtils.java
index 434b9c19..dbaa38c1 100644
--- a/test-automation-framework/org.wso2.carbon.automation.engine/src/main/java/org/wso2/carbon/automation/engine/frameworkutils/CodeCoverageUtils.java
+++ b/test-automation-framework/org.wso2.carbon.automation.engine/src/main/java/org/wso2/carbon/automation/engine/frameworkutils/CodeCoverageUtils.java
@@ -520,8 +520,26 @@ private static boolean waitForCoverageDumpFileCreation(File file) {
while (waitTime > System.currentTimeMillis()) {
if (file.length() > 0) {
+ long length1 = file.length();
+ try {
+ Thread.sleep(100);
+ } catch (InterruptedException e) {
+ log.warn("Sleep interrupted ", e);
+ }
+ long length2 = file.length();
+ if (length1 != length2) {
+ log.info("Execution data file non empty file " + file.getAbsolutePath() +
+ " is still being written.");
+ try {
+ Thread.sleep(400);
+ } catch (InterruptedException e) {
+ log.warn("Sleep interrupted ", e);
+ }
+ continue;
+ }
status = true;
- log.info("Execution data file non empty file size in KB : " + file.length() / 1024);
+ log.info("Execution data file non empty file " + file.getAbsolutePath() + " size in KB : " +
+ file.length() / 1024);
break;
} else {
diff --git a/test-automation-framework/org.wso2.carbon.automation.engine/src/main/java/org/wso2/carbon/automation/engine/testlisteners/TestTransformerListener.java b/test-automation-framework/org.wso2.carbon.automation.engine/src/main/java/org/wso2/carbon/automation/engine/testlisteners/TestTransformerListener.java
index a9b08ac1..26f88ec1 100644
--- a/test-automation-framework/org.wso2.carbon.automation.engine/src/main/java/org/wso2/carbon/automation/engine/testlisteners/TestTransformerListener.java
+++ b/test-automation-framework/org.wso2.carbon.automation.engine/src/main/java/org/wso2/carbon/automation/engine/testlisteners/TestTransformerListener.java
@@ -21,7 +21,6 @@
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.testng.IAnnotationTransformer;
-import org.testng.IAnnotationTransformer2;
import org.testng.annotations.IConfigurationAnnotation;
import org.testng.annotations.IDataProviderAnnotation;
import org.testng.annotations.IFactoryAnnotation;
@@ -39,7 +38,7 @@
import java.lang.reflect.Constructor;
import java.lang.reflect.Method;
-public class TestTransformerListener implements IAnnotationTransformer, IAnnotationTransformer2 {
+public class TestTransformerListener implements IAnnotationTransformer {
private static final Log log = LogFactory.getLog(TestTransformerListener.class);
private AutomationContext context;
@@ -160,4 +159,4 @@ public void transform(IDataProviderAnnotation iDataProviderAnnotation, Method me
public void transform(IFactoryAnnotation iFactoryAnnotation, Method method) {
//To change body of implemented methods use File | Settings | File Templates.
}
-}
\ No newline at end of file
+}
diff --git a/test-automation-framework/org.wso2.carbon.automation.engine/src/test/java/org/wso2/carbon/automation/engine/test/context/AutomationContextTestCase.java b/test-automation-framework/org.wso2.carbon.automation.engine/src/test/java/org/wso2/carbon/automation/engine/test/context/AutomationContextTestCase.java
index 207b059c..d3b7277e 100644
--- a/test-automation-framework/org.wso2.carbon.automation.engine/src/test/java/org/wso2/carbon/automation/engine/test/context/AutomationContextTestCase.java
+++ b/test-automation-framework/org.wso2.carbon.automation.engine/src/test/java/org/wso2/carbon/automation/engine/test/context/AutomationContextTestCase.java
@@ -18,11 +18,11 @@
package org.wso2.carbon.automation.engine.test.context;
-import junit.framework.Assert;
import org.testng.annotations.BeforeClass;
import org.testng.annotations.DataProvider;
import org.testng.annotations.Factory;
import org.testng.annotations.Test;
+import org.testng.Assert;
import org.wso2.carbon.automation.engine.context.AutomationContext;
import org.wso2.carbon.automation.engine.context.TestUserMode;
@@ -54,7 +54,8 @@ public void testDefaultInstance() throws XPathExpressionException {
@Test(groups = "context.unit.test", description = "Upload aar service and verify deployment")
public void testGetSuperTenant() throws XPathExpressionException {
- Assert.assertTrue(context.getSuperTenant().getTenantAdmin().getUserName().equals("admin"));
+
+ Assert.assertEquals(context.getSuperTenant().getTenantAdmin().getUserName(), "admin");
}
@Test(groups = "context.unit.test", description = "Upload aar service and verify deployment")
@@ -73,11 +74,15 @@ public void testGetConfigValue() throws XPathExpressionException {
}
@Test(groups = "context.unit.test", description = "Upload aar service and verify deployment")
public void testGetConfigNode() throws XPathExpressionException {
- Assert.assertTrue(context.getConfigurationNode("//datasources/datasource[@name='dataService']").getChildNodes().item(2).getNodeName().equals("password"));
+
+ Assert.assertEquals(
+ context.getConfigurationNode("//datasources/datasource[@name='dataService']").getChildNodes().item(2)
+ .getNodeName(), "password");
}
@Test(groups = "context.unit.test", description = "Upload aar service and verify deployment")
public void testGetCofigNodeList() throws XPathExpressionException {
- Assert.assertTrue(context.getConfigurationNodeList("//datasources/datasource").getLength()==2);
+
+ Assert.assertEquals(context.getConfigurationNodeList("//datasources/datasource").getLength(), 2);
}
@Test(groups = "context.unit.test", description = "Upload aar service and verify deployment")
public void testGetDefaultInstance() throws XPathExpressionException {
diff --git a/test-automation-framework/org.wso2.carbon.automation.extensions/pom.xml b/test-automation-framework/org.wso2.carbon.automation.extensions/pom.xml
index 4c550f17..f7c75398 100644
--- a/test-automation-framework/org.wso2.carbon.automation.extensions/pom.xml
+++ b/test-automation-framework/org.wso2.carbon.automation.extensions/pom.xml
@@ -36,7 +36,7 @@
org.apache.maven.plugins
maven-surefire-plugin
- 2.17
+ 3.3.0
default-test
@@ -47,7 +47,12 @@
- -Xmx1024m -XX:PermSize=256m -XX:MaxPermSize=512m
+
+ -Xmx1024m
+ --add-opens=java.base/java.util=ALL-UNNAMED
+ --add-opens=java.base/java.text=ALL-UNNAMED
+ --add-opens=java.desktop/java.awt.font=ALL-UNNAMED
+
1
true
diff --git a/test-automation-framework/org.wso2.carbon.automation.test.utils/pom.xml b/test-automation-framework/org.wso2.carbon.automation.test.utils/pom.xml
index 9c7f6bbc..d99d3f12 100644
--- a/test-automation-framework/org.wso2.carbon.automation.test.utils/pom.xml
+++ b/test-automation-framework/org.wso2.carbon.automation.test.utils/pom.xml
@@ -36,7 +36,7 @@
org.apache.maven.plugins
maven-surefire-plugin
- 2.17
+ 3.3.0
default-test
@@ -60,6 +60,10 @@
+
+ org.testng
+ testng
+
org.seleniumhq.selenium
selenium-java