open-vault/plugins/database/mssql
Steven Clark 2d21c00476
Add extra debugging to help identify failures within mssql test (#13142)
* Add extra debugging to help identify failures within mssql test
* Switch up the AssertInitialized method for mssql tests by marking the test as failed instead of
   immediately failing, this will also allow us to see what happens even if this assertion fails to the rest
   of the test.
2021-11-15 12:51:16 -05:00
..
mssql-database-plugin DBPW - Enables AutoMTLS for DB plugins (#10220) 2020-10-22 15:43:19 -06:00
mssql.go [VAULT-3379] Add support for contained DBs in MSSQL root rotation and lease revocation (#12839) 2021-10-19 14:11:47 -07:00
mssql_test.go Add extra debugging to help identify failures within mssql test (#13142) 2021-11-15 12:51:16 -05:00
README.md add readme on mssql testing (#6199) 2019-02-13 09:28:28 -05:00

Testing

To run these tests, first start MSSQL in Docker. Please do make sure to view the EULA before accepting it as it includes limits on the number of users per company who can be using the image, and how it can be used in testing.

sudo docker run -e 'ACCEPT_EULA=Y' -e 'SA_PASSWORD=<YourStrong!Passw0rd>' \
   -p 1433:1433 --name sql1 \
   -d mcr.microsoft.com/mssql/server:2017-latest

Then use the following env variables for testing:

export VAULT_ACC=1
export MSSQL_URL="sqlserver://SA:%3CYourStrong%21Passw0rd%3E@localhost:1433"

Note that the SA password passed into the Docker container differs from the one passed into the tests. It's the same password, but Go's libraries require it to be percent encoded.

Running all the tests at once against one Docker container will likely fail because they interact with each other. Consider running one test at a time.