-
Notifications
You must be signed in to change notification settings - Fork 191
67 lines (59 loc) · 2.3 KB
/
test-integration.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
name: Integration with Released OpenSearch
on: [push, pull_request]
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
entry:
- { opensearch_version: 1.0.1, java: 11 }
- { opensearch_version: 1.1.0, java: 11 }
- { opensearch_version: 1.2.4, java: 11 }
- { opensearch_version: 1.3.13, java: 11 }
- { opensearch_version: 2.0.1, java: 11 }
- { opensearch_version: 2.1.0, java: 11 }
- { opensearch_version: 2.2.1, java: 11 }
- { opensearch_version: 2.3.0, java: 11 }
- { opensearch_version: 2.4.1, java: 11 }
- { opensearch_version: 2.5.0, java: 11 }
- { opensearch_version: 2.6.0, java: 11 }
- { opensearch_version: 2.7.0, java: 11 }
- { opensearch_version: 2.8.0, java: 11 }
- { opensearch_version: 2.9.0, java: 11 }
- { opensearch_version: 2.10.0, java: 11 }
- { opensearch_version: 2.11.1, java: 11 }
- { opensearch_version: 2.12.0, java: 11 }
- { opensearch_version: 2.13.0, java: 11 }
steps:
- name: Checkout Java Client
uses: actions/checkout@v3
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@v3
with:
java-version: ${{ matrix.entry.java }}
distribution: 'temurin'
cache: 'gradle'
- name: Run Docker
run: |
echo "PASSWORD=admin" >> $GITHUB_ENV
docker-compose --project-directory .ci/opensearch build --build-arg OPENSEARCH_VERSION=${{ matrix.entry.opensearch_version }}
docker-compose --project-directory .ci/opensearch up -d
sleep 60
- name: Sets password (new versions)
run: |
if [[ ${{ matrix.entry.opensearch_version }} =~ ^2.1[2-9]+.[0-9]+$ ]]; then
echo "PASSWORD=0_aD^min_0" >> $GITHUB_ENV
fi
- name: Run Integration Test
run: ./gradlew clean integrationTest -Dpassword=${{ env.PASSWORD }}
- name: Upload Reports
if: failure()
uses: actions/upload-artifact@v3
with:
name: test-reports
path: java-client/build/reports/
retention-days: 7
- name: Stop Docker
run: |
docker-compose --project-directory .ci/opensearch down