public async Task RaiseIntent_CallingNonExistentIntent_ThrowsException() { await Assert.ThrowsExceptionAsync <Exception>(async() => { init(); await DesktopAgent.RaiseIntentAsync("fakeintent", null, "faketarget"); }); }
public async Task RaiseIntent_CallingNonExistentIntent_ThrowsExceptionWithMessage() { await Assert.ThrowsExceptionAsync <Exception>(async() => { try { init(); await DesktopAgent.RaiseIntentAsync("fakeintent", null, "faketarget"); } catch (Exception ex) { Assert.AreEqual(ex.Message, "No applications available to handle this intent"); throw ex; } }); }