MCPcopy Create free account
hub / github.com/Driver-C/tryssh / TestMaskSecret

Function TestMaskSecret

pkg/utils/crypto_test.go:99–104  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

97}
98
99func TestMaskSecret(t *testing.T) {
100 assert.Equal(t, "<empty>", MaskSecret(""))
101 assert.Equal(t, "****", MaskSecret("a"))
102 assert.Equal(t, "****", MaskSecret("abcd"))
103 assert.Equal(t, "****", MaskSecret("mysecretpassword"))
104}
105
106func TestGetMasterKey_EnvVar(t *testing.T) {
107 // Clear any cached master key first

Callers

nothing calls this directly

Calls 1

MaskSecretFunction · 0.85

Tested by

no test coverage detected