use container services in integration tests (#1213)
This commit is contained in:
25
.github/workflows/integration.yml
vendored
25
.github/workflows/integration.yml
vendored
@@ -8,14 +8,21 @@ on:
|
|||||||
branches:
|
branches:
|
||||||
- master
|
- master
|
||||||
|
|
||||||
|
# This ensures that previous jobs for the PR are canceled when the PR is
|
||||||
|
# updated.
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.head_ref }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
minio-test:
|
||||||
name: Integration Tests with Latest Distributed MinIO
|
name: Integration Tests with Latest Distributed MinIO
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
go-version: [1.16.x]
|
go-version: [1.16.x, 1.17.x]
|
||||||
os: [ubuntu-latest]
|
|
||||||
steps:
|
steps:
|
||||||
- name: Set up Go ${{ matrix.go-version }} on ${{ matrix.os }}
|
- name: Set up Go ${{ matrix.go-version }} on ${{ matrix.os }}
|
||||||
uses: actions/setup-go@v2
|
uses: actions/setup-go@v2
|
||||||
@@ -27,13 +34,5 @@ jobs:
|
|||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: Build on ${{ matrix.os }}
|
- name: Build on ${{ matrix.os }}
|
||||||
env:
|
|
||||||
GO111MODULE: on
|
|
||||||
GOOS: linux
|
|
||||||
CGO_ENABLED: 0
|
|
||||||
run: |
|
run: |
|
||||||
wget -O /tmp/minio https://dl.minio.io/server/minio/release/linux-amd64/minio
|
make test-integration
|
||||||
chmod +x /tmp/minio
|
|
||||||
mkdir -p /tmp/certs-dir
|
|
||||||
/tmp/minio server --quiet -S /tmp/certs-dir /tmp/fs{1...4} &
|
|
||||||
go test github.com/minio/console/integration/...
|
|
||||||
|
|||||||
5
Makefile
5
Makefile
@@ -63,6 +63,11 @@ swagger-operator:
|
|||||||
assets:
|
assets:
|
||||||
@(cd portal-ui; yarn install; make build-static; yarn prettier --write . --loglevel warn; cd ..)
|
@(cd portal-ui; yarn install; make build-static; yarn prettier --write . --loglevel warn; cd ..)
|
||||||
|
|
||||||
|
test-integration:
|
||||||
|
@(docker run -d --name minio --rm -p 9000:9000 quay.io/minio/minio:latest server /data{1...4} && sleep 5)
|
||||||
|
@(GO111MODULE=on go test -race -v github.com/minio/console/integration/...)
|
||||||
|
@(docker stop minio)
|
||||||
|
|
||||||
test:
|
test:
|
||||||
@(GO111MODULE=on go test -race -v github.com/minio/console/restapi/...)
|
@(GO111MODULE=on go test -race -v github.com/minio/console/restapi/...)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user