Skip to content

Commit

Permalink
MARP-626 Fix for Dev Fail on Market-Monitor (#37)
Browse files Browse the repository at this point in the history
  • Loading branch information
phhung-axonivy authored Aug 2, 2024
1 parent 898c2f5 commit d5a6083
Show file tree
Hide file tree
Showing 7 changed files with 63 additions and 17 deletions.
45 changes: 35 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,27 @@ on:
mvnArgs:
type: string
required: false
javaVersion:
type: number
default: 17
mvnVersion:
type: string
default: 3.6.3
schedule:
- cron: '21 21 * * *'


jobs:
build:
runs-on: ubuntu-20.04
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- name: Setup Java JDK
uses: actions/setup-java@v1.4.3
uses: actions/setup-java@v4
with:
java-version: 17
java-version: ${{ inputs.javaVersion || '17' }}
distribution: temurin

- name: Install and start SFTP
run: |
Expand All @@ -37,18 +43,37 @@ jobs:
echo "adding user to group ${sshGroup}"
sudo useradd -s /bin/bash -d /home/usr -m -g ${sshGroup} -p $(echo pwd | openssl passwd -1 -stdin) usr
- name: Setup Maven
uses: stCarolas/setup-maven@v5
with:
maven-version: ${{ inputs.mvnVersion || '3.6.3' }}

- name: Build with Maven
run: mvn clean verify --batch-mode ${{ inputs.mvnArgs }}
run: mvn clean verify --batch-mode --fail-at-end ${{ inputs.mvnArgs }}

- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v1
uses: EnricoMi/publish-unit-test-result-action@v2
if: always()
with:
files: "*/target/*-reports/TEST*.xml"
junit_files: |
*/target/*-reports/*.xml
!*/target/*-reports/failsafe-summary.xml
- name: Archive build artifacts
uses: actions/upload-artifact@v2
- name: Archive build artifact
uses: actions/upload-artifact@v4
with:
path: |
*/target/*.iar
*/target/*-[0-9]*.jar
*product/target/*.zip
- name: Archive test reports
uses: actions/upload-artifact@v4
if: failure()
with:
name: test-reports
retention-days: 5
path: |
*/target/testEngineOut.log
*/target/selenide/*
*/target/ivyEngine/deploy/*/*.deploymentLog
4 changes: 3 additions & 1 deletion .github/workflows/dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,6 @@ jobs:
build:
uses: ./.github/workflows/ci.yml
with:
mvnArgs: '"-Divy.engine.download.url=https://dev.axonivy.com/permalink/dev/axonivy-engine.zip" "-Divy.engine.version=(10.0.0,]"'
mvnArgs: '"-Divy.engine.download.url=https://dev.axonivy.com/permalink/dev/axonivy-engine.zip" "-Divy.engine.version=(10.0.0,]" "-Dproject.build.plugin.version=11.4.0-SNAPSHOT"'
javaVersion: 21
mvnVersion: 3.9.8
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ on: workflow_dispatch

jobs:
build:
uses: axonivy-market/github-workflows/.github/workflows/release.yml@v2
uses: axonivy-market/github-workflows/.github/workflows/release.yml@v4
5 changes: 4 additions & 1 deletion sftp-connector-demo/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
<artifactId>sftp-connector-demo</artifactId>
<version>10.0.1-SNAPSHOT</version>
<packaging>iar</packaging>
<properties>
<project.build.plugin.version>10.0.16</project.build.plugin.version>
</properties>
<dependencies>
<dependency>
<groupId>com.axonivy.connector.sftp</groupId>
Expand All @@ -31,7 +34,7 @@
<plugin>
<groupId>com.axonivy.ivy.ci</groupId>
<artifactId>project-build-plugin</artifactId>
<version>10.0.6</version>
<version>${project.build.plugin.version}</version>
<extensions>true</extensions>
</plugin>
</plugins>
Expand Down
17 changes: 15 additions & 2 deletions sftp-connector-test/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
<artifactId>sftp-connector-test</artifactId>
<version>10.0.1-SNAPSHOT</version>
<packaging>iar</packaging>
<properties>
<project.build.plugin.version>10.0.16</project.build.plugin.version>
<tester.version>10.0.16</tester.version>
</properties>
<dependencies>
<dependency>
<groupId>com.axonivy.connector.sftp</groupId>
Expand All @@ -16,7 +20,7 @@
<dependency>
<groupId>com.axonivy.ivy.test</groupId>
<artifactId>unit-tester</artifactId>
<version>10.0.0</version>
<version>${tester.version}</version>
<scope>test</scope>
</dependency>
</dependencies>
Expand All @@ -32,6 +36,15 @@
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
</pluginRepository>
</pluginRepositories>
<repositories>
<repository>
<id>sonatype</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<snapshots>
<updatePolicy>always</updatePolicy>
</snapshots>
</repository>
</repositories>
<build>
<testSourceDirectory>src_test</testSourceDirectory>
<pluginManagement>
Expand All @@ -49,7 +62,7 @@
<plugin>
<groupId>com.axonivy.ivy.ci</groupId>
<artifactId>project-build-plugin</artifactId>
<version>10.0.6</version>
<version>${project.build.plugin.version}</version>
<extensions>true</extensions>
</plugin>
</plugins>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
* <a href="https://developer.axonivy.com/doc/9.2/concepts/testing/process-testing.html">Process Testing docs</a>
* </p>
*/
@IvyProcessTest
@IvyProcessTest(enableWebServer = true)
public class SftpProcessTest {

private static final BpmProcess TEST_HELPER_PROCESS = BpmProcess.path("Sftp/SftpHelper");
Expand Down
5 changes: 4 additions & 1 deletion sftp-connector/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
<artifactId>sftp-connector</artifactId>
<version>10.0.1-SNAPSHOT</version>
<packaging>iar</packaging>
<properties>
<project.build.plugin.version>10.0.16</project.build.plugin.version>
</properties>
<dependencies>
<dependency>
<groupId>com.jcraft</groupId>
Expand All @@ -30,7 +33,7 @@
<plugin>
<groupId>com.axonivy.ivy.ci</groupId>
<artifactId>project-build-plugin</artifactId>
<version>10.0.6</version>
<version>${project.build.plugin.version}</version>
<extensions>true</extensions>
</plugin>
</plugins>
Expand Down

0 comments on commit d5a6083

Please sign in to comment.