public void ToHexadecimal() { FindDialogInteractor i = new FindDialogInteractor(); Assert.AreEqual(new byte[] { 0x0A }, i.ToHexadecimal("0A")); Assert.AreEqual(new byte[] { 0x0A, 0x0B }, i.ToHexadecimal("0A0b")); Assert.AreNotEqual(new byte[] { 0x0A, 0x0B }, i.ToHexadecimal("0A0C")); Assert.IsNull(i.ToHexadecimal("AGFA")); }
public void EnableFindButton() { FindDialogInteractor i = new FindDialogInteractor(); using (FindDialog dlg = i.CreateDialog()) { dlg.Show(); Assert.IsFalse(dlg.FindButton.Enabled); dlg.FindText.Text = "0ABE"; Assert.IsTrue(dlg.FindButton.Enabled); } }