diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml new file mode 100644 index 0000000..6011e83 --- /dev/null +++ b/.github/workflows/integration.yml @@ -0,0 +1,34 @@ +name: Integration + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + +jobs: + test: + name: Test + strategy: + matrix: + mssql: [2017, 2019] + runs-on: ubuntu-latest + services: + mssql: + image: mcr.microsoft.com/mssql/server:${{ matrix.mssql }}-latest + ports: + - 1433:1433 + env: + ACCEPT_EULA: Y + SA_PASSWORD: REL2021-mssql + steps: + - name: Set up Go 1.x + uses: actions/setup-go@v2 + - name: Check out code into the Go module directory + uses: actions/checkout@v2 + - name: Run go test ./... + env: + MSSQL_DATABASE: sqlserver://sa:REL2021-mssql@localhost:1433 + run: | + sleep 15 + go test -race ./...