github.com/altipla-consulting/ravendb-go-client@v0.1.3/scripts/run_single_test_multiple.ps1 (about)

     1  #!/usr/bin/env pwsh
     2  
     3  # on mac install powershell: https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-core-on-macos?view=powershell-6
     4  
     5  # this runs a single test 10 times (or until first failure).
     6  # helps find flaky tests
     7  
     8  $Env:VERBOSE_LOG = "true"
     9  $Env:LOG_HTTP_REQUEST_SUMMARY = "true"
    10  $Env:LOG_FAILED_HTTP_REQUESTS = "true"
    11  # logs output of raven server to stdout, helpful for failing tests
    12  #export LOG_RAVEN_SERVER=true
    13  $Env:LOG_ALL_REQUESTS = "true"
    14  $Env:ENABLE_FAILING_TESTS = "false"
    15  $Env:ENABLE_FLAKY_TESTS = "false"
    16  $Env:ENABLE_NORTHWIND_TESTS = "true"
    17  
    18  For ($i=0; $i -lt 10; $i++) {
    19  
    20      go clean -testcache
    21      go test -tags for_tests -v -timeout 50s ./tests -run ^TestChanges$
    22  
    23      if ($lastexitcode -ne 0) {
    24          exit
    25      }
    26  }