Windows Phone: run background agent every minute

In both Windows Phone 7 and Windows Phone 8 the background agent is executed approximately every 30 minutes. If you want to run your code more often, for example to create an app showing actual time on the live tile, you are out of luck. Are you?

You can use ScheduledActionService.LaunchForTest to test your background agent without waiting 30 minutes for the system to run it. What if you use this method in the OnInvoke method of your background agent?

Your background agent gets executed every minute!

I wonder if this code would pass certification. Has anyone tried to use it?

Update: it will not work, see Windows Phone: Don’t call LaunchForTest in Release.

This content is open source. Please help improve it.