Disable MSSQL tests until they run again

- The mssql image seems to have gotten an update that causes our tests
  to freeze instead of run, it seems to do with the create database
  calls but I haven't had time to look into it.
- Remove commented old code from circle file
This commit is contained in:
Aaron L 2017-06-08 20:52:59 -07:00
parent 9107c9dea1
commit 226517279f

View file

@ -13,10 +13,10 @@ jobs:
environment: environment:
MYSQL_ROOT_PASSWORD: mysqlpassword MYSQL_ROOT_PASSWORD: mysqlpassword
- image: microsoft/mssql-server-linux:ctp2-0 # - image: microsoft/mssql-server-linux:ctp2-0
environment: # environment:
ACCEPT_EULA: 'Y' # ACCEPT_EULA: 'Y'
SA_PASSWORD: 'R@@tr@@t1234' # SA_PASSWORD: 'R@@tr@@t1234'
environment: environment:
GOPATH: /go GOPATH: /go
@ -72,24 +72,24 @@ jobs:
sleep 1 sleep 1
done done
- run: # - run:
name: Wait for MSSQL # name: Wait for MSSQL
command: > # command: >
for i in `seq 30`; do # for i in `seq 30`; do
echo "Waiting for mssql" # echo "Waiting for mssql"
set +o errexit # set +o errexit
sqlcmd -H localhost -U sa -P R@@tr@@t1234 -Q "select * from information_schema.tables;" > /dev/null # sqlcmd -H localhost -U sa -P R@@tr@@t1234 -Q "select * from information_schema.tables;" > /dev/null
status=$? # status=$?
set -o errexit # set -o errexit
if [ $status -eq 0 ]; then # if [ $status -eq 0 ]; then
break # break
fi # fi
if [ $i -eq 30 ]; then # if [ $i -eq 30 ]; then
echo "Failed to wait for mssql" # echo "Failed to wait for mssql"
exit 1 # exit 1
fi # fi
sleep 1 # sleep 1
done # done
- run: - run:
name: Make GOPATH name: Make GOPATH
@ -108,11 +108,11 @@ jobs:
command: | command: |
mysql --host localhost --execute 'create database sqlboiler;' mysql --host localhost --execute 'create database sqlboiler;'
mysql --host localhost --database sqlboiler < $ROOTPATH/testdata/mysql_test_schema.sql mysql --host localhost --database sqlboiler < $ROOTPATH/testdata/mysql_test_schema.sql
- run: # - run:
name: Create MSSQL DB # name: Create MSSQL DB
command: | # command: |
sqlcmd -S localhost -U sa -P R@@tr@@t1234 -Q "create database sqlboiler;" # sqlcmd -S localhost -U sa -P R@@tr@@t1234 -Q "create database sqlboiler;"
sqlcmd -S localhost -U sa -P R@@tr@@t1234 -d sqlboiler -i $ROOTPATH/testdata/mssql_test_schema.sql # sqlcmd -S localhost -U sa -P R@@tr@@t1234 -d sqlboiler -i $ROOTPATH/testdata/mssql_test_schema.sql
- run: - run:
name: Build SQLBoiler name: Build SQLBoiler
@ -126,9 +126,9 @@ jobs:
- run: - run:
name: 'Configure SQLBoiler: MySQL' name: 'Configure SQLBoiler: MySQL'
command: echo -e '[mysql]\nhost="localhost"\nport=3306\nuser="root"\npass="mysqlpassword"\ndbname="sqlboiler"\nsslmode="false"\n' >> $ROOTPATH/sqlboiler.toml command: echo -e '[mysql]\nhost="localhost"\nport=3306\nuser="root"\npass="mysqlpassword"\ndbname="sqlboiler"\nsslmode="false"\n' >> $ROOTPATH/sqlboiler.toml
- run: # - run:
name: 'Configure SQLBoiler: MSSQL' # name: 'Configure SQLBoiler: MSSQL'
command: echo -e '[mssql]\nhost="localhost"\nport=1433\nuser="sa"\npass="R@@tr@@t1234"\ndbname="sqlboiler"\nsslmode="disable"\n' >> $ROOTPATH/sqlboiler.toml # command: echo -e '[mssql]\nhost="localhost"\nport=1433\nuser="sa"\npass="R@@tr@@t1234"\ndbname="sqlboiler"\nsslmode="disable"\n' >> $ROOTPATH/sqlboiler.toml
- run: - run:
name: 'Generate: PSQL' name: 'Generate: PSQL'
@ -136,9 +136,9 @@ jobs:
- run: - run:
name: 'Generate: MySQL' name: 'Generate: MySQL'
command: cd $ROOTPATH; ./sqlboiler -o mysql mysql command: cd $ROOTPATH; ./sqlboiler -o mysql mysql
- run: # - run:
name: 'Generate: MSSQL' # name: 'Generate: MSSQL'
command: cd $ROOTPATH; ./sqlboiler -o mssql mssql # command: cd $ROOTPATH; ./sqlboiler -o mssql mssql
- run: - run:
name: Download generated and test deps name: Download generated and test deps
@ -161,48 +161,3 @@ jobs:
- store_test_results: - store_test_results:
path: test_results path: test_results
#test:
# pre:
# - echo -e "[postgres]\nhost=\"localhost\"\nport=5432\nuser=\"ubuntu\"\ndbname=\"sqlboiler\"\n" > sqlboiler.toml
# - createdb -U ubuntu sqlboiler
# - psql -U ubuntu sqlboiler < ./testdata/postgres_test_schema.sql
#
# - echo -e "[mysql]\nhost=\"localhost\"\nport=3306\nuser=\"ubuntu\"\ndbname=\"sqlboiler\"\nsslmode=\"false\"\n" >> sqlboiler.toml
# - echo "create database sqlboiler;" | mysql -u ubuntu
# - mysql -u ubuntu sqlboiler < ./testdata/mysql_test_schema.sql
#
# - echo -e "[mssql]\nhost=\"localhost\"\nport=1433\nuser=\"sa\"\ndbname=\"sqlboiler\"\nsslmode=\"disable\"\n" >> sqlboiler.toml
# - docker run -e 'ACCEPT_EULA=Y' -e 'SA_PASSWORD=R@@tr@@t1234' -p 1433:1433 -d --name mssql microsoft/mssql-server-linux
# - sqlcmd -S localhost -U sa -P R@@tr@@t1234 -Q "create database sqlboiler;"
# - sqlcmd -S localhost -U sa -P R@@tr@@t1234 -d sqlboiler -i ./testdata/mssql_test_schema.sql
#
# - ./sqlboiler -o postgres postgres
# - ./sqlboiler -o mysql mysql
# - ./sqlboiler -o mssql mssql
# - cp ./testdata/mssql_test_schema.sql mssql/tables_schema.sql
# 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
# PATH: /home/ubuntu/.go_workspace/bin:/usr/local/go/bin:/home/ubuntu/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/opt/mssql-tools/bin
# 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:
# pre:
# - mkdir -p /home/ubuntu/.go_workspace/src/github.com/jstemmer
# - go get -u github.com/jstemmer/go-junit-report
#
# - curl https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
# - curl https://packages.microsoft.com/config/ubuntu/14.04/prod.list | sudo tee /etc/apt/sources.list.d/msprod.list
# - sudo apt-get update; sudo apt-get install mssql-tools unixodbc-dev
# - docker pull microsoft/mssql-server-linux
# cache_directories:
# - ~/download