-
Notifications
You must be signed in to change notification settings - Fork 49
/
.travis.yml
47 lines (40 loc) · 945 Bytes
/
.travis.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
language: go
dist: focal
go:
- 1.9.x
- 1.10.x
- 1.11.x
- 1.12.x
- 1.13.x
- 1.14.x
- 1.15.x
- 1.16.x
# - tip
addons:
apt:
packages:
- php-fpm
- python3
- python3.8-venv
env:
global:
- TEST_PHPFPM_PATH=/usr/sbin/php-fpm7.4
- GO111MODULE=on
if:
(type = pull_request AND head_repo != repo) OR
(type = push)
before_script:
# for python3 tests
- python3 -m venv myvenv
- source myvenv/bin/activate
- which python3 && python3 --version
- which pip3 && pip3 --version
- pip3 install -r example/python3/requirements.txt
# for nodejs tests
- curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.35.3/install.sh | bash
- cd ./example/nodejs && nvm install && npm install -g yarn && cd ../..
- cd ./example/nodejs && yarn install && cd ../..
# for go modules download, if applicable
- go mod download -x || go mod download || go version
script:
- go test -v -race ./...