Files
athens/scripts/ps/test_unit.ps1
marpio 2f41b2f81b Update test_unit.ps1 so that it matches the bash version. (#799)
* add default env vars

* export GO111MODULE var

* rm dups
2018-10-29 14:15:19 +01:00

14 lines
436 B
PowerShell
Executable File

# Run the unit tests with the race detector and code coverage enabled
if (!(Test-Path env:GO_ENV)) {$env:GO_ENV = "test"}
if (!(Test-Path env:ATHENS_MINIO_ENDPOINT)) {
$env:ATHENS_MINIO_ENDPOINT = "127.0.0.1:9001"
}
if (!(Test-Path env:ATHENS_MONGO_STORAGE_URL)) {
$env:ATHENS_MONGO_STORAGE_URL = "mongodb://127.0.0.1:27017"
}
$env:GO111MODULE="on"
& go test -mod=vendor -race -coverprofile cover.out -covermode atomic ./...