public void Equals_WithSameId_ShouldReturnTrue() { var id = Guid.NewGuid(); var address = TestAddress.Mainnet1; var isLocked = false; var reservations = new Collection <ReceivingAddressReservation>(); var r = new ReceivingAddress(id, address, isLocked, reservations); ReceivingAddress another; another = new ReceivingAddress(id, TestAddress.Regtest1, isLocked, reservations); Assert.True(r.Equals(another)); another = new ReceivingAddress(id, address, true, reservations); Assert.True(r.Equals(another)); another = new ReceivingAddress(id, address, isLocked, new Collection <ReceivingAddressReservation>()); Assert.True(r.Equals(another)); }
public void Equals_WithDifferentId_ShouldReturnFalse() { var id = Guid.NewGuid(); var address = TestAddress.Mainnet1; var isLocked = false; var reservations = new Collection <ReceivingAddressReservation>(); var r = new ReceivingAddress(id, address, isLocked, reservations); ReceivingAddress another = new ReceivingAddress(Guid.NewGuid(), address, isLocked, reservations); Assert.False(r.Equals(another)); }