public void FromDictionary_WithError_Works() { var dict = new NSDictionary(); dict.Add("Error", "PairingDialogResponsePending"); var value = new PairResponse(); value.FromDictionary(dict); Assert.Equal(LockdownError.PairingDialogResponsePending, value.Error); Assert.Null(value.EscrowBag); }
public void FromDictionary_WithEscrowBag_Works() { var dict = new NSDictionary(); byte[] data = new byte[] { 1, 2, 3, 4 }; dict.Add("EscrowBag", data); var value = new PairResponse(); value.FromDictionary(dict); Assert.Null(value.Error); Assert.Equal(data, value.EscrowBag); }
public void FromDictionary_ValidatesArguments() { var response = new PairResponse(); Assert.Throws <ArgumentNullException>(() => response.FromDictionary(null)); }