-
Notifications
You must be signed in to change notification settings - Fork 2
58 lines (57 loc) · 1.57 KB
/
test.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
name: Run Tests
on:
push:
tags:
- v*
branches:
- master
pull_request:
jobs:
test:
name: Integration Test
strategy:
matrix:
server:
- 7.2.2
runs-on: ubuntu-20.04
services:
couchbase:
image: couchbase:enterprise-${{ matrix.server }}
ports:
- 8091-8096:8091-8096
- 18091-18096:18091-18096
- 11210:11210
- 11207:11207
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- uses: actions/setup-go@v2
with:
go-version: 1.21
- uses: arduino/setup-protoc@v1
with:
version: 3.17
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Install Tools
run: |
go install google.golang.org/protobuf/cmd/[email protected]
go install google.golang.org/grpc/cmd/[email protected]
go install github.com/matryer/moq@latest
- name: Install Dependencies
run: go get ./...
- name: Generate Files
run: |
go generate ./...
- name: Initialize Test Cluster
run: ./.github/bin/init-cluster
- name: Check Test Cluster
run: ./.github/bin/check-cluster
- name: Setup Cluster
run: |
curl -X POST -u Administrator:password http://127.0.0.1:8091/pools/default/buckets/default/scopes/_default/collections -d name=test
- name: Run Tests
timeout-minutes: 10
env:
SGTEST_CBCONNSTR: 127.0.0.1
run: go test -v $(go list ./... | grep -v /contrib/)