Skip to content

Commit b824b1e

Browse files
committed
LOGC-49: Rename E2E test S3 credentials and remove ConfigSpec.Set
Rename LOG_COURIER_S3_* environment variables to E2E_S3_* to clarify these are test credentials, not application configuration. Remove ConfigSpec.Set calls since E2E tests don't run log-courier and don't need to configure it.
1 parent 0707fff commit b824b1e

File tree

1 file changed

+5
-9
lines changed

1 file changed

+5
-9
lines changed

test/e2e/suite_test.go

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -30,28 +30,24 @@ var _ = BeforeSuite(func() {
3030
err := logcourier.ConfigSpec.LoadConfiguration("", "", nil)
3131
Expect(err).NotTo(HaveOccurred())
3232

33-
// Override S3 config for E2E tests
33+
// Get S3 credentials for test operations
3434
// Check environment variables first, fall back to defaults
35-
endpoint := os.Getenv("LOG_COURIER_S3_ENDPOINT")
35+
endpoint := os.Getenv("E2E_S3_ENDPOINT")
3636
if endpoint == "" {
3737
endpoint = testS3Endpoint
3838
}
3939

40-
accessKey := os.Getenv("LOG_COURIER_S3_ACCESS_KEY_ID")
40+
accessKey := os.Getenv("E2E_S3_ACCESS_KEY_ID")
4141
if accessKey == "" {
4242
accessKey = testAccessKeyID
4343
}
4444

45-
secretKey := os.Getenv("LOG_COURIER_S3_SECRET_ACCESS_KEY")
45+
secretKey := os.Getenv("E2E_S3_SECRET_ACCESS_KEY")
4646
if secretKey == "" {
4747
secretKey = testSecretAccessKey
4848
}
4949

50-
logcourier.ConfigSpec.Set("s3.endpoint", endpoint)
51-
logcourier.ConfigSpec.Set("s3.access-key-id", accessKey)
52-
logcourier.ConfigSpec.Set("s3.secret-access-key", secretKey)
53-
54-
// Create shared S3 client
50+
// Create shared S3 client for test operations
5551
sharedS3Client = s3.NewFromConfig(aws.Config{
5652
Region: testRegion,
5753
Credentials: aws.CredentialsProviderFunc(func(ctx context.Context) (aws.Credentials, error) {

0 commit comments

Comments
 (0)