26 lines
1,001 B
YAML
26 lines
1,001 B
YAML
test:
|
|
pre:
|
|
- mkdir -p /home/ubuntu/.go_workspace/src/github.com/jstemmer
|
|
- git clone git@github.com:nullbio/go-junit-report.git /home/ubuntu/.go_workspace/src/github.com/jstemmer/go-junit-report
|
|
- go install github.com/jstemmer/go-junit-report
|
|
- echo -e "[postgres]\nhost=\"localhost\"\nport=5432\nuser=\"ubuntu\"\ndbname=\"sqlboiler\"" > sqlboiler.toml
|
|
- createdb -U ubuntu sqlboiler
|
|
- psql -U ubuntu sqlboiler < ./testdata/test_schema.sql
|
|
- ./sqlboiler postgres
|
|
override:
|
|
- go test -v -race ./... > $CIRCLE_ARTIFACTS/gotest.txt
|
|
post:
|
|
- cat $CIRCLE_ARTIFACTS/gotest.txt | go-junit-report > $CIRCLE_TEST_REPORTS/junit.xml
|
|
|
|
machine:
|
|
environment:
|
|
GODIST: "go1.7.linux-amd64.tar.gz"
|
|
post:
|
|
- mkdir -p download
|
|
- test -e download/$GODIST || curl -o download/$GODIST https://storage.googleapis.com/golang/$GODIST
|
|
- sudo rm -rf /usr/local/go
|
|
- sudo tar -C /usr/local -xzf download/$GODIST
|
|
|
|
dependencies:
|
|
cache_directories:
|
|
- ~/download
|