public bool CanStartAdhocMeeting(IAudioVideoInvitation invitation) { #pragma warning disable CS0618 // Type or member is obsolete return(invitation.Supports(AudioVideoInvitationCapability.StartAdhocMeeting)); #pragma warning restore CS0618 // Type or member is obsolete }
public void ShouldNotExposeAcceptCapabilityIfLinkNotAvailable() { // Given IAudioVideoInvitation invitation = null; m_applicationEndpoint.HandleIncomingAudioVideoCall += (sender, args) => invitation = args.NewInvite; // When TestHelper.RaiseEventsFromFile(m_mockEventChannel, "Event_IncomingAudioCall_NoActionLinks.json"); // Then Assert.IsNotNull(invitation); Assert.IsFalse(invitation.Supports(AudioVideoInvitationCapability.Accept)); }
public void ShouldExposeForwardCapabilityIfLinkAvailable() { // Given IAudioVideoInvitation invitation = null; m_applicationEndpoint.HandleIncomingAudioVideoCall += (sender, args) => { invitation = args.NewInvite; }; // When TestHelper.RaiseEventsFromFile(m_mockEventChannel, "Event_IncomingAudioCall.json"); // Then Assert.IsNotNull(invitation); Assert.IsTrue(invitation.Supports(AudioVideoInvitationCapability.Forward)); }
public void ShouldNotSupportStartAdhocMeetingIfLinkNotAvailable() { // Given IAudioVideoInvitation invitation = null; m_applicationEndpoint.HandleIncomingAudioVideoCall += (sender, args) => invitation = args.NewInvite; TestHelper.RaiseEventsFromFile(m_mockEventChannel, "Event_IncomingAudioCall_NoActionLinks.json"); // When var supports = invitation.Supports(AudioVideoInvitationCapability.StartAdhocMeeting); // Then Assert.IsFalse(supports); }
public void ShouldNotSupportAcceptAndBridgeIfLinkIsNotAvailable() { // Given IAudioVideoInvitation invitation = null; m_applicationEndpoint.HandleIncomingAudioVideoCall += (sender, args) => invitation = args.NewInvite; m_restfulClient.OverrideResponse(new Uri(DataUrls.AudioVideoInvitationForward), HttpMethod.Post, HttpStatusCode.NoContent, null); TestHelper.RaiseEventsFromFile(m_mockEventChannel, "Event_IncomingAudioCall_NoActionLink.json"); // When var supports = invitation.Supports(AudioVideoInvitationCapability.AcceptAndBridge); // Then Assert.IsFalse(supports); }