private void CTRL_Action_UPD_ItemSelected(object sender, RoutedEventArgs e) { if (DeleteDevices != null) { DeleteDevices?.Invoke(sender, null); } }
public void DeleteDevices() { string expected = File.ReadAllText(Path.Combine(_requestsTestDataPath, "DeleteDevices.xml")); var request = new DeleteDevices { SessionId = "sid", DevicesList = new TPropertyStringList { Val = new List <string> { "abcd1234" } } }; var xml = request.ToXml().InnerXmlFormatted(); Assert.AreEqual(expected, xml); XmlDocument doc = new XmlDocument(); doc.LoadXml(File.ReadAllText(Path.Combine(_responsesTestDataPath, "DeleteDevices.xml"))); var response = request.FromHttpRequestResult(new HttpRequestResult { Response = doc.InnerXml }); Assert.AreEqual("result", response.Type); Assert.True(response.Success); }
/// <summary> /// Closes the delete device popup. /// </summary> private void CloseDeleteDevicePopup() { var deleteDevicesPopup = DeleteDevices.FindName("DeleteDevicesPopup") as Popup; deleteDevicesPopup.IsOpen = false; }
/// <summary> /// Opens the delete device popup. /// </summary> private void OpenDeleteDevicePopup() { var deleteDevicesPopup = DeleteDevices.FindName("DeleteDevicesPopup") as Popup; deleteDevicesPopup.IsOpen = true; }