(t *testing.T)
| 32 | ) |
| 33 | |
| 34 | func TestMasterKey_Encrypt(t *testing.T) { |
| 35 | key, err := createTestKMSKeyIfNotExists() |
| 36 | assert.NoError(t, err) |
| 37 | |
| 38 | data := []byte("to be or not to be static bytes") |
| 39 | assert.NoError(t, key.Encrypt(data)) |
| 40 | assert.NotEmpty(t, key.EncryptedDataKey()) |
| 41 | assert.NotEqual(t, data, key.EncryptedKey) |
| 42 | } |
| 43 | |
| 44 | func TestMasterKey_Decrypt(t *testing.T) { |
| 45 | key, err := createTestKMSKeyIfNotExists() |
nothing calls this directly
no test coverage detected