Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit006600e

Browse files
authored
chore(enterprise/dbcrypt): adjust behaviour of TestHelpMeEncryptSomeValue (#17116)
This "utility test" isn't so useful if you have to uncomment the`t.Skip()` before using it.
1 parent0d8d5f2 commit006600e

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

‎enterprise/dbcrypt/cipher_internal_test.go‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,9 +100,10 @@ func TestCiphersBackwardCompatibility(t *testing.T) {
100100
// 3. Copy the value from the test output and do what you need with it.
101101
funcTestHelpMeEncryptSomeValue(t*testing.T) {
102102
t.Parallel()
103-
t.Skip("this only exists if you need to encrypt a value with dbcrypt, it does not actually test anything")
104-
105103
valueToEncrypt:=os.Getenv("ENCRYPT_ME")
104+
ifvalueToEncrypt=="" {
105+
t.Skip("Set ENCRYPT_ME to some value you need to encrypt")
106+
}
106107
t.Logf("valueToEncrypt: %q",valueToEncrypt)
107108
keys:=os.Getenv("CODER_EXTERNAL_TOKEN_ENCRYPTION_KEYS")
108109
require.NotEmpty(t,keys,"Set the CODER_EXTERNAL_TOKEN_ENCRYPTION_KEYS environment variable to use this")

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp