-
Notifications
You must be signed in to change notification settings - Fork 36
129 lines (114 loc) · 5.56 KB
/
actions.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
name: Test report
on:
workflow_dispatch:
paths-ignore:
- '**.md'
pull_request:
paths-ignore:
- '**.md'
push:
paths-ignore:
- '**.md'
env:
MAVEN_OPTS: -Dmaven.wagon.http.retryHandler.class=standard -Dmaven.wagon.http.retryHandler.count=3 -Dhttp.keepAlive=false -Dmaven.wagon.http.pool=false -Dmaven.wagon.httpconnectionManager.ttlSeconds=120
permissions: read-all
jobs:
tests:
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
include:
# Java 17 tests
- name: "Unit tests - Java 17"
java_version: 17
test_suite: 'test -Djava.version=17 jacoco:report'
- name: "Style check - Java 17"
java_version: 17
test_suite: 'compile -Djava.version=17 com.mycila:license-maven-plugin:check pmd:pmd pmd:cpd pmd:check pmd:cpd-check javadoc:jar'
- name: "Standalone integration 4.0 - Java 17"
java_version: 17
test_suite: 'verify -P docker-integration-test,standalone-integration-tests -Dit.cassandra.version=4.0 -Djava.version=17 -DskipUTs'
artifacts_dir: "standalone-integration/target"
- name: "Standalone integration 4.1 - Java 17"
java_version: 17
test_suite: 'verify -P docker-integration-test,standalone-integration-tests -Dit.cassandra.version=4.1 -Djava.version=17 -DskipUTs'
artifacts_dir: "standalone-integration/target"
- name: "Standalone integration 5.0 - Java 17"
java_version: 17
test_suite: 'verify -P docker-integration-test,standalone-integration-tests -Dit.cassandra.version=5.0 -Djava.version=17 -DskipUTs'
artifacts_dir: "standalone-integration/target"
- name: "Python integration - Java 17"
java_version: 17
test_suite: 'verify -P docker-integration-test,python-integration-tests -Dit.cassandra.version=5.0 -Djava.version=17 -DskipUTs'
artifacts_dir: "ecchronos-binary/target"
# Java 21 tests
- name: "Unit tests - Java 21"
java_version: 21
test_suite: 'test -Dnet.bytebuddy.experimental=true -Djava.version=21 jacoco:report'
- name: "Style check - Java 21"
java_version: 21
test_suite: 'compile -Djava.version=21 com.mycila:license-maven-plugin:check pmd:pmd pmd:cpd pmd:check pmd:cpd-check javadoc:jar'
- name: "Standalone integration 4.0 - Java 21"
java_version: 21
test_suite: 'verify -P docker-integration-test,standalone-integration-tests -Dit.cassandra.version=4.0 -Djava.version=21 -DskipUTs'
artifacts_dir: "standalone-integration/target"
- name: "Standalone integration 4.1 - Java 21"
java_version: 21
test_suite: 'verify -P docker-integration-test,standalone-integration-tests -Dit.cassandra.version=4.1 -Djava.version=21 -DskipUTs'
artifacts_dir: "standalone-integration/target"
- name: "Standalone integration 5.0 - Java 21"
java_version: 21
test_suite: 'verify -P docker-integration-test,standalone-integration-tests -Dit.cassandra.version=5.0 -Djava.version=21 -DskipUTs'
artifacts_dir: "standalone-integration/target"
- name: "Python integration - Java 21"
java_version: 21
test_suite: 'verify -P docker-integration-test,python-integration-tests -Dit.cassandra.version=5.0 -Djava.version=21 -DskipUTs'
artifacts_dir: "ecchronos-binary/target"
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Cache local Maven repository
uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
with:
path: ~/.m2/repository
key: build-${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
build-${{ runner.os }}-maven-
- name: Set up JDK ${{ matrix.java_version }}
uses: actions/setup-java@8df1039502a15bceb9433410b1a100fbe190c53b # v4.5.0
with:
java-version: ${{ matrix.java_version }}
distribution: 'temurin'
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Python 3
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
with:
python-version: 3
- name: Install black
run: python -m pip install black==24.10.0
- name: Run black in the check mode
run: black --check --verbose --line-length 120 ./ecchronos-binary/src
- name: install dependencies
run: mvn install -DskipTests=true
- run: mvn $TEST_SUITE -B
id: tests
env:
TEST_SUITE: ${{ matrix.test_suite }}
- name: Upload artifacts
if: ${{ failure() && steps.tests.conclusion == 'failure' }}
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: ${{ matrix.name }}-cassandra-logs
path: ${{ matrix.artifacts_dir }}/cassandra*.log
if-no-files-found: 'ignore'
- name: Upload coverage to Codecov
uses: codecov/codecov-action@7f8b4b4bde536c465e797be725718b88c5d95e0e # v5.1.1
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: false
files: >
./rest/target/site/jacoco/jacoco.xml,
./application/target/site/jacoco/jacoco.xml,
./core/target/site/jacoco/jacoco.xml,
./fm.impl/target/site/jacoco/jacoco.xml,
./connection/target/site/jacoco/jacoco.xml