How to Properly Use Windows Phone 8 Store Test Kit - windows-phone-8

I have followed the directions on http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh394032(v=vs.105).aspx regarding the steps to ensure my application will pass the certification process. However, in the automated testing section the website shows a screenshot of the Store Test Kit, and at the bottom of the screenshot is a button that says 'Start Windows Phone Application Analysis'. I click this and attempt to run the first option, yet it seems to never stop. I have ran it for a few hours and then given up. Is this supposed to take this long? I am using the release build of my application, have completed the App Details portion, and ran the Automated Tests. It seems like the next step is to perform the 'Start Windows Phone Application Analysis' which I cannot seem to complete?

The 'Windows Phone Application Analysis' is not an automated test utility. When you run it, it will launch the app and then the expectation is that you interact with / use the app while it logs details of the run. When you close the app it will generate a report based on what it recorded while it was being used.

Related

How to make Windows 10 Store "forget" an app download for testing purposes?

I'm testing my Win32 app converted to UWP, so I'm new to the whole Windows 10 Store concept.
So far I was able to get my app certified & published in the store via a private link. Now I would like to download and test it, but there's an issue.
The first time someone sees the app it has the following options:
but once you get it, all you see is this:
and even if you log in under a different Microsoft account (on the same computer), or previously uninstall the app, you get this:
and "free trial" simply installs it w/o a trial in that case.
So my question is, how do I make Windows Store "forget" that I have this app?
If you have bought the app you can't undo that, but you can always create a new user who has never bought for the testing purpose.
EDIT: Windows Store is for real transactions and not for testing. If you want to test, you should have a custom build that uses CurrentAppSimulator instead of CurrentApp

Deploying Windows app directly to Surface without going through the store

I’ve built a windows app using Cordova and I want to deploy it privately on my Window Surface Pro.
I can deploy it for testing purposes with the developer certificate that is being generate automatically, but it’s only valid for 90 days. Is there a way to premaritally deploy apps on Surface Pro or at least extend the 90 days period?
Thanks
You want to go in Project -> Windows Store -> Create Application Packages
Then select "No" on the first page. You can leave everything else as it is and click next and create.
This will give you 2 files which you need to copy to your Windows Surface. Once this is done go look in the folder that was created and run the Powershell situated inside. Your application is now installed on your device
Go take a look here for more detailed informations

Run Windows Phone App in background without UI

I am developing a Windows phone 8 app that need to run only in background with UI. Is there any way I can run the app in the background, or without actually being open?
It depends upon what you want to do in the background. Generally speaking you can't implement something like a Windows service that will startup automatically when the phone is launched.
That said you can run your app in the background within given limitations. Check out MSDN for detailed information.
Why all these limitations you might ask yourself? It's to provide a good battery life to the user.
Edit:
For the periodic agent to start running the app must be started once. Further the agent must update a live tile (user must pin it to the start screen) or the app has to be once opened every 14 days.
Another option might be using push notifications to trigger an update..

Any Tips for getting Windows Phone 8 Resource Intensive Task to Run?

I have been trying to get a Resource-Intensive Task background agent to run in release mode after deploying to the phone for several days and have never seen it run. Has anyone got this to work outside of the debugger? How long did you have to wait before it ran?
I am able to launch and successfully run the Resource-Intensive Task using the LaunchForTest but have never gotten it to run as it should in release mode even though the task shows that it is scheduled. I have followed the samples and the phone should have met the requirements for launch. I have set the manifest up for auto-upload as well so shouldn't need to set an expiration date on the task.
The phone is plugged in and charging and battery is 100%.
The phone has wifi access.
The phone is on the lock screen and left this way over night for 2 nights.
I have tried this both on a Nokia Lumia 920 and HTC699OL
I am able to get a Periodic Task to run but not the Resource-Intensive Task. If the Periodic runs, I'm assuming I have configured everything correctly in the WMAppManifest and the Resource-Intensive Task should run at some point?
The Resource-Intensive Task shows the following:
IsEnabled = true
IsShceduled = true
LastScheduledTime: 1/1/0001 12:00:00
ExpirationTime: 12/31/9999 11:59:59
LastExitReason: None
The app shows up in the Settings > Background tasks > advanced.
Running the Store Kit test shows no API call problems for the phone application and I have a reference to the agent project from the main phone app project.
Here is my WMAppManifest setting for the agent:
<ExtendedTask Name="BackgroundTask">
<BackgroundServiceAgent Name="SML.Sync.WP8.Agent" Specifier="ScheduledTaskAgent" Source="SML.Sync.WP8.Agent" Type="SML.Sync.WP8.Agent.BackgroundUploadAgent" />
</ExtendedTask>
This seems correct based on the MSDN documentation here: MSDN Task Element documentation
Here is the auto-upload extension, which follows the Tokens node:
<Extensions>
<Extension ExtensionName="Photos_Auto_Upload" ConsumerID="{5B04B775-356B-4AA0-AAF8-6491FFEA5632}" TaskID="_default" />
</Extensions>
I have also tried it without the auto-upload setting and had the same result of never running.
I have also tried getting the example from here http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh202941(v=vs.105).aspx to run but after removing the debug_agent and deploying as release mode, I see the same issue, never gets run even though it says its scheduled - periodic does run just not resource-intensive.
I know that the documentation says that it may never run but it seems like 2 days passing and meeting the task requirements should work. Do I need to wait a week to see if this sucker runs?
Would be greatly appreciative of any guidance or tips if you have gotten a Resource-Intensive task to actually run in release mode.
I opened a support incident with Microsoft on February 4th 2013 and heard back from them February 5th with the following:
I collaborated with the internal Windows Phone developers and
confirmed the following:
ResourceIntensiveTask (i.e. Resource Intensive Agent) does not get triggered in the Windows Phone 8 operating system in Release Mode.
FYI, Auto-upload uses ResourceIntensiveTasks, so it does not work in WP8 either.
A fix is scheduled for inclusion in a future Windows OS update, most likely later this spring. The fix needs to propagate through the
OEMs who build their hardware-specific versions of the Windows Phone 8
OS.
There is no known immediate/official workaround.
The recent GDR2 update has fixed this. I verified that Resource-Intensive Task is running on my phone.
If you want to upload something in background, maybe you dont even need this Task. You could give this a try:
http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh202955%28v=vs.105%29.aspx
Sample is here:
http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh202959%28v=vs.105%29.aspx

windows phone 8: how to check if there are new messages on the database (server) all the time (even if the app is not running)?

I’ve been developing Windows desktop applications for many years, but just started developing Windows Phone 8 applications so, as you can imagine, I have many questions and doubts.
This is my problem so far:
I need an application to check any certain time if there are new messages / notifications in the server database, even if the application is not running, and show it (in some way, not sure how) on the phone. At the end, I want something similar to Facebook application (or others) that checks constantly if there are new messages even if I’m not using the phone.
How can I do that? Is there any tutorial or guide that explains that?
Thank you very much
There's two mechanisms available on Windows Phone to periodically check a data source and display notifications:
Push notifications: the server directly sends the notification to the phone. It provides the best user experience, because the notification is send (nearly) instantaneously, and because all the processing is done server-side (so it doesn't impact the phone's autonomy). The obvious drawback is that you need a server infrastructure to send the notifications.
Background agents: your application runs in background, is woke up periodically (every 30 minutes or so), and is allowed to run for about 15 seconds. During those 15 seconds, you can check your data source, and display a notification if needed. The two major drawbacks are that you can't choose when you're background agent executes (so the notification can be displayed 30 minutes late), and it'll have an impact on the battery life.
What you need is push notifications.
Microsoft already provides this functionality throught Azure Mobile Services and here is something to get you started : Get started with push notifications in Mobile Services