mirror of
https://github.com/bitwarden/mobile
synced 2025-01-16 02:42:20 +01:00
fix crypto tests
This commit is contained in:
parent
3ad4e28a2c
commit
bdb8b5ea39
@ -26,12 +26,13 @@ namespace Bit.App.Test
|
||||
{
|
||||
var storageService = Substitute.For<ISecureStorageService>();
|
||||
var keyService = Substitute.For<IKeyDerivationService>();
|
||||
storageService.Contains("key").Returns(true);
|
||||
storageService.Retrieve("key").Returns(
|
||||
Convert.FromBase64String("QpSYI5k0bLQXEygUEHn4wMII3ERatuWDFBszk7JAhbQ="));
|
||||
|
||||
var service = new CryptoService(storageService, keyService);
|
||||
var encryptedHi = service.Encrypt(value);
|
||||
return service.Decrypt(encryptedHi);
|
||||
var encryptedValue = service.Encrypt(value);
|
||||
return service.Decrypt(encryptedValue);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user