From 1a1c888fb4d0f8f2ddf2be62ac09ada9648a9778 Mon Sep 17 00:00:00 2001 From: HiteshRepo Date: Tue, 30 Jan 2024 16:59:48 +0530 Subject: [PATCH] pass test dir --- .github/workflows/ci.yml | 3 ++- src/pkg/storage/testdata/storage.go | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 28e3f2625..8ff5e93ca 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -180,6 +180,7 @@ jobs: CORSO_SECONDARY_M365_TEST_USER_ID: ${{ vars.CORSO_SECONDARY_M365_TEST_USER_ID }} CORSO_PASSPHRASE: ${{ secrets.INTEGRATION_TEST_CORSO_PASSPHRASE }} S3_BUCKET: ${{ secrets.CI_TESTS_S3_BUCKET }} + TEST_DIR: /tmp/corso-trusted-testlog run: | set -euo pipefail go test \ @@ -218,7 +219,7 @@ jobs: uses: actions/upload-artifact@v4 with: name: ci-test-log - path: /tmp/* + path: /tmp/corso-trusted-testlog/* if-no-files-found: error retention-days: 14 diff --git a/src/pkg/storage/testdata/storage.go b/src/pkg/storage/testdata/storage.go index b5b3e877f..eb7966412 100644 --- a/src/pkg/storage/testdata/storage.go +++ b/src/pkg/storage/testdata/storage.go @@ -33,6 +33,9 @@ func NewPrefixedS3Storage(t tester.TestT) storage.Storage { now := tester.LogTimeOfTest(t) dir := t.TempDir() + if givenDir := os.Getenv("TEST_DIR"); len(givenDir) > 0 { + dir = givenDir + } fmt.Println("----------------->", dir)