-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.test.yml
More file actions
179 lines (168 loc) · 5.22 KB
/
Copy pathdocker-compose.test.yml
File metadata and controls
179 lines (168 loc) · 5.22 KB
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
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
version: '3.8'
services:
# Base test service with shared configuration
test-base:
build:
context: .
dockerfile: Dockerfile.test
image: serengeti-test:latest
volumes:
- ./test-results:/app/test-results
- ~/.m2:/root/.m2
environment:
- JAVA_OPTS=-Xmx1024m -XX:+UseG1GC -XX:MaxGCPauseMillis=100
- MAVEN_OPTS=-Xmx1024m
networks:
- test-network
# Unit tests service
unit-tests:
extends:
service: test-base
container_name: serengeti-unit-tests
command: >
mvn test -Dtest=com.ataiva.serengeti.unit.storage.StorageSchedulerTest -Pjacoco
volumes:
- ./test-results/unit:/app/target/surefire-reports
- ./test-results/coverage/unit:/app/target/site/jacoco
deploy:
resources:
limits:
cpus: '2'
memory: 2G
# Fast tests service
fast-tests:
extends:
service: test-base
container_name: serengeti-fast-tests
command: >
mvn test -Dtest=com.ataiva.serengeti.storage.StorageSchedulerFastTest,com.ataiva.serengeti.storage.lsm.StorageSchedulerFastTest -Pjacoco
volumes:
- ./test-results/fast:/app/target/surefire-reports
- ./test-results/coverage/fast:/app/target/site/jacoco
deploy:
resources:
limits:
cpus: '1'
memory: 1G
# Integration tests service
integration-tests:
extends:
service: test-base
container_name: serengeti-integration-tests
command: >
mvn test -Dtest=com.ataiva.serengeti.integration.StorageSchedulerIntegrationTest -Pjacoco
volumes:
- ./test-results/integration:/app/target/surefire-reports
- ./test-results/coverage/integration:/app/target/site/jacoco
deploy:
resources:
limits:
cpus: '2'
memory: 2G
# Property tests service
property-tests:
extends:
service: test-base
container_name: serengeti-property-tests
command: >
mvn test -Dtest=com.ataiva.serengeti.property.StorageSchedulerPropertyTest -Pjacoco
volumes:
- ./test-results/property:/app/target/surefire-reports
- ./test-results/coverage/property:/app/target/site/jacoco
deploy:
resources:
limits:
cpus: '2'
memory: 2G
# Benchmark tests service
benchmark-tests:
extends:
service: test-base
container_name: serengeti-benchmark-tests
command: >
mvn test -Pbenchmark -Djmh.includes=StorageSchedulerBenchmark -Djmh.args="-wi 2 -i 3 -f 1 -rf json -rff /app/test-results/benchmark/results.json"
volumes:
- ./test-results/benchmark:/app/target/benchmarks
deploy:
resources:
limits:
cpus: '4'
memory: 4G
# Chaos tests service
chaos-tests:
extends:
service: test-base
container_name: serengeti-chaos-tests
command: >
mvn test -Dtest=com.ataiva.serengeti.chaos.StorageSchedulerChaosTest -Pchaos-testing,jacoco
volumes:
- ./test-results/chaos:/app/target/surefire-reports
- ./test-results/coverage/chaos:/app/target/site/jacoco
deploy:
resources:
limits:
cpus: '2'
memory: 2G
# Mutation tests service
mutation-tests:
extends:
service: test-base
container_name: serengeti-mutation-tests
command: >
mvn test -Pstorage-scheduler-mutation
volumes:
- ./test-results/mutation:/app/target/pit-reports
deploy:
resources:
limits:
cpus: '2'
memory: 3G
# All tests service
all-tests:
extends:
service: test-base
container_name: serengeti-all-tests
command: >
bash -c "
mvn test -Dtest=com.ataiva.serengeti.unit.storage.StorageSchedulerTest -Pjacoco &&
mvn test -Dtest=com.ataiva.serengeti.storage.StorageSchedulerFastTest,com.ataiva.serengeti.storage.lsm.StorageSchedulerFastTest -Pjacoco &&
mvn test -Dtest=com.ataiva.serengeti.integration.StorageSchedulerIntegrationTest -Pjacoco &&
mvn test -Dtest=com.ataiva.serengeti.property.StorageSchedulerPropertyTest -Pjacoco &&
mvn test -Dtest=com.ataiva.serengeti.chaos.StorageSchedulerChaosTest -Pchaos-testing,jacoco &&
mvn test -Pbenchmark -Djmh.includes=StorageSchedulerBenchmark -Djmh.args='-wi 2 -i 3 -f 1 -rf json -rff /app/test-results/benchmark/results.json' &&
mvn test -Pstorage-scheduler-mutation
"
volumes:
- ./test-results:/app/test-results
- ./test-results/coverage:/app/target/site/jacoco
deploy:
resources:
limits:
cpus: '4'
memory: 4G
# Windows-specific test service
windows-tests:
extends:
service: test-base
container_name: serengeti-windows-tests
image: mcr.microsoft.com/windows/servercore:ltsc2022
platform: windows/amd64
command: >
powershell -Command "
$env:JAVA_HOME = 'C:\\Program Files\\Eclipse Adoptium\\jdk-11.0.19.7-hotspot';
$env:PATH = \"$env:JAVA_HOME\\bin;$env:PATH\";
cd C:\\app;
.\\mvnw.cmd test -Dtest=com.ataiva.serengeti.unit.storage.StorageSchedulerTest
"
volumes:
- ./test-results/windows:/app/target/surefire-reports
deploy:
resources:
limits:
cpus: '2'
memory: 4G
profiles:
- windows
networks:
test-network:
driver: bridge