1
0
mirror of https://github.com/bitwarden/server.git synced 2024-11-25 12:45:18 +01:00
bitwarden-server/test/Core.Test/Models/CipherTests.cs
Matt Gibson 7eaf7ab770
[Bug] Fix cipher clone yielding incorrect RevisionDate (#1031)
* Fix cipher clone yielding incorrect RevisionDate

* PR fixes

Co-authored-by: Matt Gibson <mdgibson@Matts-MBP.lan>
2020-12-07 19:35:34 -06:00

19 lines
467 B
C#

using Bit.Core.Models.Table;
using Bit.Core.Test.AutoFixture.CipherFixtures;
using Newtonsoft.Json;
using Xunit;
namespace Core.Test.Models
{
public class CipherTests
{
[Theory]
[InlineUserCipherAutoData]
[InlineOrganizationCipherAutoData]
public void Clone_CreatesExactCopy(Cipher cipher)
{
Assert.Equal(JsonConvert.SerializeObject(cipher), JsonConvert.SerializeObject(cipher.Clone()));
}
}
}