-
Notifications
You must be signed in to change notification settings - Fork 8
44 lines (38 loc) · 967 Bytes
/
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
name: Python application
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
runs-on: ubuntu-latest
services:
mysql:
image: mysql:8.0
env:
MYSQL_ROOT_PASSWORD: sqlpass
MYSQL_DATABASE: mysql
ports: ['3306:3306']
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.8
uses: actions/setup-python@v3
with:
python-version: "3.8"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest
pip install -r requirements.txt
- name: Test
env:
binance_api_key: ${{ secrets.BINANCE_API_KEY }}
binance_api_secret: ${{ secrets.BINANCE_API_SECRET }}
ftx_api_key: ${{ secrets.FTX_API_KEY }}
ftx_api_secret: ${{ secrets.FTX_API_SECRET }}
sql_password: 'sqlpass'
run: |
python api.py &
sleep 5
pytest