From 226517279fb98cff3392c7f054a42d24a7445e92 Mon Sep 17 00:00:00 2001 From: Aaron L Date: Thu, 8 Jun 2017 20:52:59 -0700 Subject: [PATCH] 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 --- .circleci/config.yml | 111 +++++++++++++------------------------------ 1 file changed, 33 insertions(+), 78 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 88bcff4..00ab82c 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -13,10 +13,10 @@ jobs: environment: MYSQL_ROOT_PASSWORD: mysqlpassword - - image: microsoft/mssql-server-linux:ctp2-0 - environment: - ACCEPT_EULA: 'Y' - SA_PASSWORD: 'R@@tr@@t1234' +# - image: microsoft/mssql-server-linux:ctp2-0 +# environment: +# ACCEPT_EULA: 'Y' +# SA_PASSWORD: 'R@@tr@@t1234' environment: GOPATH: /go @@ -72,24 +72,24 @@ jobs: sleep 1 done - - run: - name: Wait for MSSQL - command: > - for i in `seq 30`; do - echo "Waiting for mssql" - set +o errexit - sqlcmd -H localhost -U sa -P R@@tr@@t1234 -Q "select * from information_schema.tables;" > /dev/null - status=$? - set -o errexit - if [ $status -eq 0 ]; then - break - fi - if [ $i -eq 30 ]; then - echo "Failed to wait for mssql" - exit 1 - fi - sleep 1 - done +# - run: +# name: Wait for MSSQL +# command: > +# for i in `seq 30`; do +# echo "Waiting for mssql" +# set +o errexit +# sqlcmd -H localhost -U sa -P R@@tr@@t1234 -Q "select * from information_schema.tables;" > /dev/null +# status=$? +# set -o errexit +# if [ $status -eq 0 ]; then +# break +# fi +# if [ $i -eq 30 ]; then +# echo "Failed to wait for mssql" +# exit 1 +# fi +# sleep 1 +# done - run: name: Make GOPATH @@ -108,11 +108,11 @@ jobs: command: | mysql --host localhost --execute 'create database sqlboiler;' mysql --host localhost --database sqlboiler < $ROOTPATH/testdata/mysql_test_schema.sql - - run: - name: Create MSSQL DB - command: | - 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 +# - run: +# name: Create MSSQL DB +# command: | +# 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 - run: name: Build SQLBoiler @@ -126,9 +126,9 @@ jobs: - run: name: 'Configure SQLBoiler: MySQL' command: echo -e '[mysql]\nhost="localhost"\nport=3306\nuser="root"\npass="mysqlpassword"\ndbname="sqlboiler"\nsslmode="false"\n' >> $ROOTPATH/sqlboiler.toml - - run: - 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 +# - run: +# 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 - run: name: 'Generate: PSQL' @@ -136,9 +136,9 @@ jobs: - run: name: 'Generate: MySQL' command: cd $ROOTPATH; ./sqlboiler -o mysql mysql - - run: - name: 'Generate: MSSQL' - command: cd $ROOTPATH; ./sqlboiler -o mssql mssql +# - run: +# name: 'Generate: MSSQL' +# command: cd $ROOTPATH; ./sqlboiler -o mssql mssql - run: name: Download generated and test deps @@ -161,48 +161,3 @@ jobs: - store_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