re-enable stderr logs in tests (#2215)
## Does this PR need a docs update or release note? - [x] ⛔ No ## Type of change - [x] 🐛 Bugfix - [x] 🤖 Test - [x] 💻 CI/Deployment ## Test Plan - [x] 💪 Manual
This commit is contained in:
parent
b6a7095c7f
commit
e43455cc49
3
.github/workflows/ci.yml
vendored
3
.github/workflows/ci.yml
vendored
@ -208,6 +208,7 @@ jobs:
|
||||
CORSO_M365_TEST_USER_ID: ${{ secrets.CORSO_M365_TEST_USER_ID }}
|
||||
CORSO_SECONDARY_M365_TEST_USER_ID: ${{ secrets.CORSO_SECONDARY_M365_TEST_USER_ID }}
|
||||
CORSO_PASSPHRASE: ${{ secrets.INTEGRATION_TEST_CORSO_PASSPHRASE }}
|
||||
CORSO_LOG_FILE: stderr
|
||||
LOG_GRAPH_REQUESTS: true
|
||||
run: |
|
||||
set -euo pipefail
|
||||
@ -219,7 +220,7 @@ jobs:
|
||||
-p 1 \
|
||||
./... 2>&1 | tee ./testlog/gotest.log | gotestfmt -hide successful-tests
|
||||
|
||||
# Upload the original go test log as an artifact for later review.
|
||||
# Upload the original go test output as an artifact for later review.
|
||||
- name: Upload test log
|
||||
if: failure()
|
||||
uses: actions/upload-artifact@v3
|
||||
|
||||
1
.github/workflows/load_test.yml
vendored
1
.github/workflows/load_test.yml
vendored
@ -53,6 +53,7 @@ jobs:
|
||||
AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}
|
||||
AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
|
||||
CORSO_LOAD_TESTS: true
|
||||
CORSO_LOG_FILE: stderr
|
||||
CORSO_M365_LOAD_TEST_USER_ID: ${{ secrets.CORSO_M365_LOAD_TEST_USER_ID }}
|
||||
CORSO_M365_LOAD_TEST_ORG_USERS: ${{ secrets.CORSO_M365_LOAD_TEST_ORG_USERS }}
|
||||
CORSO_PASSPHRASE: ${{ secrets.CORSO_PASSPHRASE }}
|
||||
|
||||
@ -106,6 +106,11 @@ func PreloadLoggingFlags() (string, string) {
|
||||
return "info", dlf
|
||||
}
|
||||
|
||||
// if not specified, attempt to fall back to env declaration.
|
||||
if len(logfile) == 0 {
|
||||
logfile = os.Getenv("CORSO_LOG_FILE")
|
||||
}
|
||||
|
||||
if logfile == "-" {
|
||||
logfile = "stdout"
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user