Skip to content

Commit 35b0504

Browse files
author
TheSnoozer
committed
#491: use set-env and add-path directives to ensure that our custom maven version will be used for integration-tests
1 parent 41147d4 commit 35b0504

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

.github/workflows/default-tests.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,10 @@ jobs:
7575
export PATH=$M2_HOME/bin:$PATH;
7676
mvn -version;
7777
fi'
78+
- name: Setup M2_HOME Environment variable
79+
run: echo "::set-env name=M2_HOME::${PWD}/apache-maven-${{ matrix.maven_version }}"
80+
- name: Setup System Path to use the custom Maven
81+
run: echo "::add-path::${M2_HOME}/bin"
7882
- name: Cache local Maven repository
7983
uses: actions/cache@v1
8084
with:
@@ -85,7 +89,7 @@ jobs:
8589
key: ${{ runner.os }}-maven-${{ matrix.maven_version }}-m2-${{ hashFiles('**/pom.xml') }}
8690
restore-keys: ${{ runner.os }}-maven-${{ matrix.maven_version }}-m2
8791
- name: Verify Setup of Maven ${{ matrix.maven_version }}
88-
run: mvn -version
92+
run: bash -c "echo ${M2_HOME}; echo ${PATH}; mvn -version"
8993
- name: Install a test version with Maven
9094
run: mvn clean install -B
9195
- name: Run the local testversion with Maven

0 commit comments

Comments
 (0)