@@ -1194,6 +1194,52 @@ jobs:
1194
1194
./restapi/coverage/
1195
1195
key : ${{ runner.os }}-coverage-restapi-2-${{ github.run_id }}
1196
1196
1197
+ test-operatorapi-on-go :
1198
+ name : Test Operatorapi on Go ${{ matrix.go-version }} and ${{ matrix.os }}
1199
+ needs :
1200
+ - lint-job
1201
+ - no-warnings-and-make-assets
1202
+ - reuse-golang-dependencies
1203
+ - vulnerable-dependencies-checks
1204
+ - semgrep-static-code-analysis
1205
+ runs-on : ${{ matrix.os }}
1206
+ strategy :
1207
+ matrix :
1208
+ go-version : [ 1.17.x ]
1209
+ os : [ ubuntu-latest ]
1210
+ steps :
1211
+ - name : Set up Go ${{ matrix.go-version }} on ${{ matrix.os }}
1212
+ uses : actions/setup-go@v2
1213
+ with :
1214
+ go-version : ${{ matrix.go-version }}
1215
+ id : go
1216
+
1217
+ - name : Check out code into the Go module directory
1218
+ uses : actions/checkout@v2
1219
+
1220
+ - uses : actions/cache@v2
1221
+ name : Go Mod Cache
1222
+ with :
1223
+ path : |
1224
+ ~/.cache/go-build
1225
+ ~/go/pkg/mod
1226
+ key : ${{ runner.os }}-go-${{ github.run_id }}
1227
+
1228
+ - name : Build on ${{ matrix.os }}
1229
+ env :
1230
+ GO111MODULE : on
1231
+ GOOS : linux
1232
+ run : |
1233
+ make test-unit-test-operator
1234
+
1235
+ - uses : actions/cache@v2
1236
+ id : coverage-cache-unittest-operatorapi
1237
+ name : Coverage Cache unit test operatorAPI
1238
+ with :
1239
+ path : |
1240
+ ./operatorapi/coverage/
1241
+ key : ${{ runner.os }}-coverage-unittest-operatorapi-2-${{ github.run_id }}
1242
+
1197
1243
b-integration-tests :
1198
1244
name : Integration Tests with Latest Distributed MinIO
1199
1245
needs :
@@ -1286,6 +1332,7 @@ jobs:
1286
1332
needs :
1287
1333
- b-integration-tests
1288
1334
- test-restapi-on-go
1335
+ - test-operatorapi-on-go
1289
1336
- c-operator-api-tests
1290
1337
- test-pkg-on-go
1291
1338
- sso-integration
@@ -1356,6 +1403,14 @@ jobs:
1356
1403
./restapi/coverage/
1357
1404
key : ${{ runner.os }}-coverage-restapi-2-${{ github.run_id }}
1358
1405
1406
+ - uses : actions/cache@v2
1407
+ id : coverage-cache-unittest-operatorapi
1408
+ name : Coverage Cache unit test operatorAPI
1409
+ with :
1410
+ path : |
1411
+ ./operatorapi/coverage/
1412
+ key : ${{ runner.os }}-coverage-unittest-operatorapi-2-${{ github.run_id }}
1413
+
1359
1414
- uses : actions/cache@v2
1360
1415
id : coverage-cache-pkg
1361
1416
name : Coverage Cache Pkg
@@ -1375,7 +1430,7 @@ jobs:
1375
1430
echo "go build gocoverage.go"
1376
1431
go build gocovmerge.go
1377
1432
echo "put together the outs for final coverage resolution"
1378
- ./gocovmerge ../integration/coverage/system.out ../replication/coverage/replication.out ../sso-integration/coverage/sso-system.out ../restapi/coverage/coverage.out ../pkg/coverage/coverage-pkg.out ../operator-integration/coverage/operator-api.out > all.out
1433
+ ./gocovmerge ../integration/coverage/system.out ../replication/coverage/replication.out ../sso-integration/coverage/sso-system.out ../restapi/coverage/coverage.out ../pkg/coverage/coverage-pkg.out ../operator-integration/coverage/operator-api.out ../operatorapi/coverage/coverage-unit-test-operatorapi.out > all.out
1379
1434
echo "Download mc for Ubuntu"
1380
1435
wget -q https://dl.min.io/client/mc/release/linux-amd64/mc
1381
1436
echo "Change the permissions to execute mc command"
0 commit comments