ci: add backtest sync test to ci flow

This commit is contained in:
c9s 2022-05-20 16:48:23 +08:00
parent 728190a78f
commit 62de3a43ed
No known key found for this signature in database
GPG Key ID: 7385E7E464CB0A54
2 changed files with 29 additions and 1 deletions

View File

@ -7,7 +7,6 @@ on:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
@ -68,3 +67,9 @@ jobs:
- name: TestDnum
run: go test -tags dnum -v ./pkg/...
- name: Create dotenv file
run: |
echo "DB_DRIVER=mysql" >> .env.local
echo "DB_DSN=root:root@/bbgo" >> .env.local

23
config/backtest.yaml Normal file
View File

@ -0,0 +1,23 @@
---
backtest:
startTime: "2022-01-01"
endTime: "2022-01-02"
symbols:
- BTCUSDT
sessions:
- binance
- ftx
- max
- kucoin
- okex
exchangeStrategies:
- on: binance
grid:
symbol: BTCUSDT
quantity: 0.001
gridNumber: 100
profitSpread: 1000.0 # The profit price spread that you want to add to your sell order when your buy order is executed
upperPrice: 40_000.0
lowerPrice: 20_000.0