-
Notifications
You must be signed in to change notification settings - Fork 3
61 lines (59 loc) · 1.45 KB
/
tests.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
59
60
61
name: test-all
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
workflow_dispatch:
jobs:
test:
name: run all tests
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
python-version: [3.6, 3.7, 3.8, 3.9, 'pypy3']
services:
victoria:
image: gistart/victoria-metrics:v1.59.0
env:
httpListenAddr: :8428
influxListenAddr: :8491
ports:
- 8428:8428
- 8491:8491
- 8491:8491/udp
statsd-exporter:
image: prom/statsd-exporter:v0.20.2
ports:
- 9102:9102
- 9125:9125
- 9125:9125/udp
pushgateway:
image: prom/pushgateway:v1.4.0
ports:
- 9091:9091
steps:
- name: checkout
uses: actions/checkout@v2
- name: python${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: pip-requirements
run: pip install --upgrade -e .[test]
- name: run-test
run: pytest
env:
VM_HOST: localhost
VM_API_PORT: 8428
VM_INFLUX_PORT: 8491
STATSD_HOST: localhost
STATSD_API_PORT: 9102
STATSD_UDP_PORT: 9125
PUSHGW_HOST: localhost
PUSHGW_PORT: 9091
- name: upload-cov
uses: codecov/codecov-action@v1
with:
files: coverage.xml