You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
709 B
26 lines
709 B
using System.Text.Json; |
|
using Bit.Core.Test.AutoFixture.CipherFixtures; |
|
using Bit.Core.Vault.Entities; |
|
using Bit.Test.Common.AutoFixture.Attributes; |
|
using Xunit; |
|
|
|
namespace Bit.Core.Test.Models; |
|
|
|
public class CipherTests |
|
{ |
|
[Theory] |
|
[UserCipherCustomize] |
|
[BitAutoData] |
|
public void Clone_UserCipher_CreatesExactCopy(Cipher cipher) |
|
{ |
|
Assert.Equal(JsonSerializer.Serialize(cipher), JsonSerializer.Serialize(cipher.Clone())); |
|
} |
|
|
|
[Theory] |
|
[OrganizationCipherCustomize] |
|
[BitAutoData] |
|
public void Clone_OrganizationCipher_CreatesExactCopy(Cipher cipher) |
|
{ |
|
Assert.Equal(JsonSerializer.Serialize(cipher), JsonSerializer.Serialize(cipher.Clone())); |
|
} |
|
}
|
|
|