public void SendWindowsPhone7TilePushNotificationMessageTest()
        {
            var message = WindowsPhonePushNotificationMessageUnitTest.GetValidWindowsPhoneTilePushNotificationMessage();

            var result = PushNotifier.SendPushNotificationMessage(message);

            WindowsPhonePushNotificationMessageUnitTest.AssertOperationResultValidationResultsMessageCodeOnPushNotificationSendResult(result, ResultType.Success, true, true);
        }
        public void WindowsPhoneTilePushNotificationMessageCountGreaterThan99Test()
        {
            var message = WindowsPhonePushNotificationMessageUnitTest.GetValidWindowsPhoneTilePushNotificationMessage();

            message.Count = 100;

            var result = PushNotifier.SendPushNotificationMessage(message);

            WindowsPhonePushNotificationMessageUnitTest.AssertOperationResultValidationResultsMessageCodeOnPushNotificationSendResult(result, ResultType.Success, false, true, "0008");
        }
        public void WindowsPhoneTilePushNotificationMessageBackContentForWindowsPhone7_0Test()
        {
            var message = WindowsPhonePushNotificationMessageUnitTest.GetValidWindowsPhoneTilePushNotificationMessage();

            message.SupportWindowsPhone7_0 = true;
            message.BackContent            = "Back Content - Profile Image";

            var result = PushNotifier.SendPushNotificationMessage(message);

            WindowsPhonePushNotificationMessageUnitTest.AssertOperationResultValidationResultsMessageCodeOnPushNotificationSendResult(result, ResultType.Success, false, true, "0007");
        }
        public void WindowsPhoneTilePushNotificationMessageBackBackgroundImageUriForWindowsPhone7_0Test()
        {
            var message = WindowsPhonePushNotificationMessageUnitTest.GetValidWindowsPhoneTilePushNotificationMessage();

            message.SupportWindowsPhone7_0 = true;
            message.BackBackgroundImageUri = "http://download-codeplex.sec.s-msft.com/download/Avatar.ashx?DownloadId=266566";

            var result = PushNotifier.SendPushNotificationMessage(message);

            WindowsPhonePushNotificationMessageUnitTest.AssertOperationResultValidationResultsMessageCodeOnPushNotificationSendResult(result, ResultType.Success, false, true, "0005");
        }
        public void SendAsyncWindowsPhoneTilePushNotificationMessageTest()
        {
            var returned = false;
            var message  = WindowsPhonePushNotificationMessageUnitTest.GetValidWindowsPhoneTilePushNotificationMessage();

            PushNotifier.SendPushNotificationMessageAsync(message, (result) =>
            {
                WindowsPhonePushNotificationMessageUnitTest.AssertOperationResultValidationResultsMessageCodeOnPushNotificationSendResult(result, ResultType.Success, true, true);
                returned = true;
            });

            while (!returned)
            {
                System.Threading.Thread.Sleep(500);
            }
        }