Skip to content

Commit eef7236

Browse files
committed
update with last functionalities
1 parent 3e876ce commit eef7236

126 files changed

Lines changed: 2021 additions & 926 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

pom.xml

Lines changed: 21 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,15 @@
44
<modelVersion>4.0.0</modelVersion>
55
<groupId>fr.axa.automation.webengine</groupId>
66
<artifactId>webengine-parent</artifactId>
7-
<version>3.0.11</version>
7+
<version>3.1.14</version>
88
<packaging>pom</packaging>
99
<name>webengine-parent</name>
1010

11-
<distributionManagement>
12-
<repository>
13-
<id>github</id>
14-
<name>GitHub Packages</name>
15-
<url>https://maven.pkg.github.com/AxaFrance/webengine-java</url>
16-
</repository>
17-
</distributionManagement>
11+
<parent>
12+
<groupId>fr.axa.socle.axafr</groupId>
13+
<artifactId>axafr-corporate-parent</artifactId>
14+
<version>2.0.3</version>
15+
</parent>
1816

1917
<properties>
2018
<java-source.version>1.8</java-source.version>
@@ -69,22 +67,24 @@
6967
<poi.version>5.2.3</poi.version>
7068

7169
<jackson-core.version>2.13.2</jackson-core.version>
70+
<maven-deploy-plugin.version>3.1.1</maven-deploy-plugin.version>
7271
</properties>
7372

7473
<modules>
7574
<module>webengine-util</module>
75+
<module>webengine-js</module>
7676
<module>webengine-report</module>
7777
<module>webengine-core</module>
7878
<module>webengine-web</module>
7979
<module>webengine-runner</module>
80-
<module>webengine-boot-keyword-driven</module>
81-
<module>webengine-test-keyword-driven</module>
8280
<module>webengine-boot-gherkin</module>
83-
<module>webengine-test-gherkin</module>
84-
<module>webengine-test-linear</module>
85-
<module>webengine-report-jacoco-aggregate</module>
81+
<module>webengine-boot-keyword-driven</module>
8682
<module>webengine-drive-by-excel</module>
8783
<module>webengine-cmd-line</module>
84+
<module>webengine-report-jacoco-aggregate</module>
85+
<module>webengine-test-linear</module>
86+
<module>webengine-test-gherkin</module>
87+
<module>webengine-test-keyword-driven</module>
8888
</modules>
8989

9090
<dependencies>
@@ -461,6 +461,14 @@
461461
</execution>
462462
</executions>
463463
</plugin>
464+
<plugin>
465+
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-deploy-plugin -->
466+
467+
<groupId>org.apache.maven.plugins</groupId>
468+
<artifactId>maven-deploy-plugin</artifactId>
469+
<version>${maven-deploy-plugin.version}</version>
470+
471+
</plugin>
464472

465473
</plugins>
466474
<pluginManagement>

webengine-boot-gherkin/pom.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,10 @@
55
<parent>
66
<groupId>fr.axa.automation.webengine</groupId>
77
<artifactId>webengine-parent</artifactId>
8-
<version>3.0.11</version>
8+
<version>3.1.14</version>
99
</parent>
1010

1111
<artifactId>webengine-boot-gherkin</artifactId>
12-
<version>3.0.11</version>
1312
<packaging>jar</packaging>
1413
<name>webengine-boot-gherkin</name>
1514

webengine-boot-gherkin/src/main/java/fr/axa/automation/webengine/helper/WebdriverHelper.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ private static Optional<GlobalConfiguration> getConfig() throws Exception {
3939
}
4040

4141
public static Optional<WebDriver> getDefaultDriver() throws WebEngineException {
42-
return BrowserFactory.getWebDriver(Platform.WINDOWS, Browser.CHROMIUM_EDGE);
42+
return BrowserFactory.getWebDriver(Platform.WINDOWS, Browser.CHROMIUM_EDGE,true);
4343
}
4444

4545
public static void quiDriver(WebDriver webDriver) throws WebEngineException {

webengine-boot-keyword-driven/pom.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,10 @@
55
<parent>
66
<groupId>fr.axa.automation.webengine</groupId>
77
<artifactId>webengine-parent</artifactId>
8-
<version>3.0.11</version>
8+
<version>3.1.14</version>
99
</parent>
1010

1111
<artifactId>webengine-boot-keyword-driven</artifactId>
12-
<version>3.0.11</version>
1312
<packaging>jar</packaging>
1413
<name>webengine-boot-keyword-driven</name>
1514

webengine-boot-keyword-driven/src/main/java/fr/axa/automation/webengine/boot/BootProject.java

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -61,29 +61,21 @@ public void runTestSuite(CommandLine commandLine) throws WebEngineException, IOE
6161
ITestSuite testSuite = TestSuiteHelper.getTestSuite();
6262
AbstractGlobalApplicationContext globalApplicationContext = getGlobalApplicationContext(commandLine, testSuite);
6363

64-
loggerService.info("Start Phase initialize test suite ");
6564
testSuiteExecutor.initialize(globalApplicationContext);
66-
loggerService.info("End Phase initialize ");
67-
68-
loggerService.info("Start run test ");
6965
if (testSuite instanceof AbstractTestSuite) {
7066
((AbstractTestSuite) testSuite).setGlobalApplicationContext(globalApplicationContext);
7167
}
7268
TestSuiteReport testSuiteReport = ((ITestSuiteWebExecutor)testSuiteExecutor).run(globalApplicationContext, testSuite);
73-
loggerService.info("End run test ");
74-
75-
loggerService.info("Start clean ");
7669
testSuiteExecutor.cleanUp(globalApplicationContext);
77-
loggerService.info("End clean ");
78-
79-
loggerService.info("Start report ");
8070
Map<ReportPathKey,String> reportsPath = reportHelper.generateReports(testSuiteReport, testSuite.getClass().getSimpleName(), globalApplicationContext.getSettings().getOutputDir());
81-
loggerService.info("End report ");
8271

8372
if(globalApplicationContext.getSettings().isShowReport()) {
84-
loggerService.info("Open report ");
8573
reportHelper.openReport(reportsPath.get(ReportPathKey.HTML_REPORT_PATH_KEY) + File.separator + "index.html");
86-
loggerService.info("End open report ");
74+
}
75+
if(testSuiteReport!=null && testSuiteReport.getFailed()>0){
76+
String errorMsg = "Test suite failed. Total number of test case :" + testSuiteReport.getNumberOfTestcase() +". Number of failed test : "+testSuiteReport.getFailed();
77+
loggerService.error(errorMsg);
78+
throw new WebEngineException(errorMsg);
8779
}
8880
}
8981

webengine-cmd-line/pom.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,10 @@
66
<parent>
77
<groupId>fr.axa.automation.webengine</groupId>
88
<artifactId>webengine-parent</artifactId>
9-
<version>3.0.11</version>
9+
<version>3.1.14</version>
1010
</parent>
1111

1212
<artifactId>webengine-cmd-line</artifactId>
13-
<version>3.0.11</version>
1413
<packaging>jar</packaging>
1514
<name>webengine-cmd-line</name>
1615

webengine-core/pom.xml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,10 @@
55
<parent>
66
<groupId>fr.axa.automation.webengine</groupId>
77
<artifactId>webengine-parent</artifactId>
8-
<version>3.0.11</version>
8+
<version>3.1.14</version>
99
</parent>
1010

1111
<artifactId>webengine-core</artifactId>
12-
<version>3.0.11</version>
1312
<packaging>jar</packaging>
1413
<name>webengine-core</name>
1514

@@ -21,6 +20,13 @@
2120
<version>${project.parent.version}</version>
2221
</dependency>
2322

23+
<dependency>
24+
<groupId>fr.axa.automation.webengine</groupId>
25+
<artifactId>webengine-js</artifactId>
26+
<version>${project.parent.version}</version>
27+
</dependency>
28+
29+
2430
<dependency>
2531
<groupId>org.springframework.boot</groupId>
2632
<artifactId>spring-boot-starter</artifactId>

webengine-core/src/main/java/fr/axa/automation/webengine/core/AbstractTestSuiteExecutor.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,9 @@ protected AbstractTestSuiteExecutor(ITestCaseExecutor testCaseExecutor, ILocalTe
2323
}
2424

2525
public Object initialize(AbstractGlobalApplicationContext globalApplicationContext) {
26+
loggerService.info("Start Phase initialize test suite ");
2627
runLocalTesting(globalApplicationContext);
28+
loggerService.info("End Phase initialize ");
2729
return null;
2830
}
2931

@@ -32,7 +34,9 @@ private void runLocalTesting(AbstractGlobalApplicationContext globalApplicationC
3234
}
3335

3436
public void cleanUp(Object object) {
37+
loggerService.info("Start clean ");
3538
stopLocalTesting();
39+
loggerService.info("End clean ");
3640
}
3741

3842
private void stopLocalTesting() {

webengine-core/src/main/java/fr/axa/automation/webengine/properties/WebengineConfiguration.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,7 @@ public class WebengineConfiguration {
1818
String name;
1919
String platformName = null;
2020
String browserName = null;
21-
String browserVersion = null;
2221
List<String> browserOptionList;
2322
String outputDir;
2423
AppiumConfiguration appiumConfiguration;
2524
}
26-

webengine-drive-by-excel/pom.xml

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,10 @@
55
<parent>
66
<groupId>fr.axa.automation.webengine</groupId>
77
<artifactId>webengine-parent</artifactId>
8-
<version>3.0.11</version>
8+
<version>3.1.14</version>
99
</parent>
1010

1111
<artifactId>webengine-drive-by-excel</artifactId>
12-
<version>3.0.11</version>
1312
<packaging>jar</packaging>
1413
<name>webengine-drive-by-excel</name>
1514

@@ -147,7 +146,7 @@
147146
<artifactId>maven-dependency-plugin</artifactId>
148147
<executions>
149148
<execution>
150-
<id>unpack</id>
149+
<id>unpack-report</id>
151150
<phase>generate-resources</phase>
152151
<goals>
153152
<goal>unpack</goal>
@@ -165,9 +164,27 @@
165164
</artifactItems>
166165
</configuration>
167166
</execution>
167+
<execution>
168+
<id>unpack-js</id>
169+
<phase>generate-resources</phase>
170+
<goals>
171+
<goal>unpack</goal>
172+
</goals>
173+
<configuration>
174+
<artifactItems>
175+
<artifactItem>
176+
<groupId>fr.axa.automation.webengine</groupId>
177+
<artifactId>webengine-js</artifactId>
178+
<version>${project.parent.version}</version>
179+
<type>jar</type>
180+
<includes>js/**</includes>
181+
<outputDirectory>${basedir}/src/main/resources/</outputDirectory>
182+
</artifactItem>
183+
</artifactItems>
184+
</configuration>
185+
</execution>
168186
</executions>
169187
</plugin>
170-
171188
</plugins>
172189
</build>
173190
</project>

0 commit comments

Comments
 (0)