Run transformation integration tests in parallel

Signed-off-by: Anish Ramasekar <anish.ramasekar@gmail.com>
This commit is contained in:
Anish Ramasekar 2024-04-09 18:01:26 -07:00
parent 1e048d5f24
commit 689363be06
No known key found for this signature in database
GPG Key ID: E96F745A34A409C2
3 changed files with 19 additions and 11 deletions

View File

@ -890,7 +890,10 @@ func TestEncryptionConfigHotReloadFilePolling(t *testing.T) {
}
for _, tc := range testCases {
tc := tc
t.Run(tc.name, func(t *testing.T) {
t.Parallel()
socketPath := getSocketPath()
encryptionConfig := fmt.Sprintf(`
kind: EncryptionConfiguration

View File

@ -412,6 +412,7 @@ func TestKMSv2ProviderKeyIDStaleness(t *testing.T) {
}
func testKMSv2ProviderKeyIDStaleness(t *testing.T) {
t.Parallel()
socketPath := getSocketPath()
encryptionConfig := fmt.Sprintf(`
kind: EncryptionConfiguration
@ -1347,6 +1348,7 @@ func TestKMSv2ProviderLegacyData(t *testing.T) {
}
func testKMSv2ProviderLegacyData(t *testing.T) {
t.Parallel()
socketPath := getSocketPath()
encryptionConfig := fmt.Sprintf(`
kind: EncryptionConfiguration

View File

@ -85,10 +85,12 @@ func TestSecretsShouldBeTransformed(t *testing.T) {
// TODO: add secretbox
}
for _, tt := range testCases {
tt := tt
t.Run(tt.transformerPrefix, func(t *testing.T) {
t.Parallel()
test, err := newTransformTest(t, tt.transformerConfigContent, false, "", nil)
if err != nil {
t.Fatalf("failed to setup test for envelop %s, error was %v", tt.transformerPrefix, err)
continue
}
test.secret, err = test.createSecret(testSecret, testNamespace)
if err != nil {
@ -96,6 +98,7 @@ func TestSecretsShouldBeTransformed(t *testing.T) {
}
test.runResource(test.logger, tt.unSealFunc, tt.transformerPrefix, "", "v1", "secrets", test.secret.Name, test.secret.Namespace)
test.cleanUp()
})
}
}