2016-06-09 00:12:13 +02:00
|
|
|
language: go
|
2018-10-11 10:31:05 +02:00
|
|
|
cache:
|
|
|
|
directories:
|
2019-05-24 02:39:37 +02:00
|
|
|
- ~/bitcoin/bitcoin-0.18.0/bin
|
2018-10-11 10:31:05 +02:00
|
|
|
- $GOCACHE
|
2018-11-29 02:18:21 +01:00
|
|
|
- $GOPATH/pkg/mod
|
2018-10-11 10:31:05 +02:00
|
|
|
- $GOPATH/src/github.com/btcsuite
|
|
|
|
- $GOPATH/src/github.com/golang
|
|
|
|
- $GOPATH/src/gopkg.in/alecthomas
|
|
|
|
|
2018-11-16 11:08:16 +01:00
|
|
|
go:
|
2019-09-04 04:06:00 +02:00
|
|
|
- "1.13.x"
|
2018-11-16 11:08:16 +01:00
|
|
|
|
|
|
|
env:
|
2018-10-11 10:31:05 +02:00
|
|
|
global:
|
|
|
|
- GOCACHE=$HOME/.go-build
|
2018-11-16 11:08:16 +01:00
|
|
|
matrix:
|
2018-11-30 06:27:49 +01:00
|
|
|
- RACE=true
|
2018-11-16 11:08:16 +01:00
|
|
|
- ITEST=true
|
2019-05-24 14:17:49 +02:00
|
|
|
- NEUTRINO_ITEST=true
|
2019-07-11 13:51:22 +02:00
|
|
|
- BITCOIND_ITEST=true
|
2018-11-30 06:27:49 +01:00
|
|
|
- COVER=true
|
2018-10-11 10:31:05 +02:00
|
|
|
|
2018-01-17 17:07:31 +01:00
|
|
|
sudo: required
|
2018-10-11 10:31:05 +02:00
|
|
|
|
2016-07-26 01:39:22 +02:00
|
|
|
script:
|
2018-11-30 06:40:47 +01:00
|
|
|
- export GO111MODULE=on
|
2019-05-22 07:58:50 +02:00
|
|
|
- bash ./scripts/install_bitcoind.sh
|
2018-11-29 02:18:21 +01:00
|
|
|
|
2018-10-11 10:31:05 +02:00
|
|
|
# Run unit tests with race condition detector.
|
2018-12-01 00:20:46 +01:00
|
|
|
- 'if [ "$RACE" = true ]; then make travis-race ; fi'
|
2018-10-11 10:31:05 +02:00
|
|
|
|
2019-05-24 14:17:49 +02:00
|
|
|
# Run btcd integration tests.
|
2019-02-01 08:47:15 +01:00
|
|
|
- 'if [ "$ITEST" = true ]; then make travis-itest; fi'
|
2018-10-11 10:31:05 +02:00
|
|
|
|
2019-05-24 14:17:49 +02:00
|
|
|
# Run neutrino integration tests.
|
|
|
|
- 'if [ "$NEUTRINO_ITEST" = true ]; then make travis-itest backend=neutrino; fi'
|
|
|
|
|
2019-07-11 13:51:22 +02:00
|
|
|
# Run bitcoind integration tests.
|
|
|
|
- 'if [ "$BITCOIND_ITEST" = true ]; then make travis-itest backend=bitcoind; fi'
|
|
|
|
|
2018-10-11 10:31:05 +02:00
|
|
|
# Run unit tests and generate coverage report.
|
2018-12-01 00:20:46 +01:00
|
|
|
- 'if [ "$COVER" = true ]; then make travis-cover; fi'
|
2018-10-11 10:31:05 +02:00
|
|
|
|
2017-10-18 00:42:22 +02:00
|
|
|
after_script:
|
2019-06-04 23:51:25 +02:00
|
|
|
- LOG_FILES=./lntest/itest/*.log
|
|
|
|
- echo "Uploading to termbin.com..." && find $LOG_FILES | xargs -I{} sh -c "cat {} | nc termbin.com 9999 | xargs -r0 printf '{} uploaded to %s'"
|
|
|
|
- echo "Uploading to file.io..." && tar -zcvO $LOG_FILES | curl -s -F 'file=@-;filename=logs.tar.gz' https://file.io | xargs -r0 printf 'logs.tar.gz uploaded to %s\n'
|