Simulating iOS opening an app fresh in the background - ios

I have a crash in an iOS app that I believe it triggered from iOS opening the app in the background. I'd like to be able to test this hypothesis, but am not sure if I can trigger iOS to open a closed app in the background for testing purposes.
I am specifically looking to have iOS open this app fresh - i.e. not when the app is still active and placed in the background, but when the app is fully closed and iOS triggers a re-open.
Is this possible?

Related

How to start Apple Watch app when user makes some action in iOS app

I was told multiple times that other apps do this but I can't seem to find any documentation on how to do that.
The behavior I would like to achieve is:
User starts iOS app and navigates to particular screen.
User presses start action/workout button and starts action/workout on iOS app.
At the same time user's Watch wakes up and shows corresponding screen in Watch app which acts as info screen for the current action/workout in iOS app.
User can press pause button on Watch and pause the action/workout in iOS app (this part is working already via WCSession).
So the question is basically how can I launch Watch app when either iOS app starts or when user does something in iOS app?
P.S. It is not a question of launching iOS app from Watch app, AFAIK for that I can use handoff.

App is not working in background on iOS 10.1.1

I am working on chatting/calling app. To make it work in background mode I've enabled these modes:
It is working very fine with iOS 9.3.4, iOS 10.
Working means it is receiving messages, calls, responding to server when in background, even though there is no call is in progress.
When I run it on iPhone6 with iOS 10.1.1, it is stopping responding when enters in background.
Anyone faced this anytime? Any workaround found?
I am using Xcode8.2 Beta
I also tried enabling Background Fetch mode, but didn't helped!
UPDATE
It is working in background only when any call is in progress on iOS 10.1.1.
Actually I gone through various reads on net, it says that iOS10 is stopped supporting for background app execution for VoIP apps.
To run VoIP apps in background, there is no way.
My ap was running in background on iOS10 was because I was building it against iOS9 SDK on Xcode 7.
Only one thing we can do is use PushKit Framework and get VoIP silent notifications to awake the app in background!

iOS simulator dropping managed objects on entering background

When my app is running on simulator and I press the home button it enters the background properly. But when I put the app back in the foreground, it has apparently dropped all the managed objects in memory, and the app crashes when I try to resume using it. There's no code in the any of the callbacks for the app changing state that would cause that, and the app has never displayed this behavior before.
What changed was going to xCode 6 / iOS 8 on the simulator, and I also applied "Reset content and settings" in response to this problem.
The app behaves problem-free on actual devices, both iOS 7 and iOS 8. Is this another bug with the new iOS simulator?
If you did "reset content and settings" with the app in the background, you probably blew away all its context. You should terminate the apps in the background before running that.

iOS 8 app goes background in open

After iOS 8 release, we are getting feedback from some users about our app that whenever users try to start app, operating system navigate it to background. I was able to examine this issue myself and I see that OS does not terminate app or app does not crash. In fact, app appears in background apps menu. Whenever user tries to open the app it closes itself something as if “simulating user's home button touch”. Of course, I’m not doing something like this by code. And this issue only show 100 in 1 and only in iOS 8 devices. It shows any kind of devices from iPhone 4S to 5S.
Have you ever encounter an issue like this?

How to run the iOS App when screen is locked [duplicate]

This question already has an answer here:
Background downloading even if the phone gets locked
(1 answer)
Closed 8 years ago.
I am downloading some files from server using NSURLConnection. It works fine when app is in foreground or background. App is not running when iPhone Screen is locked.
My client want the App to run in locked mode also. Is there any way to download the data when screen is locked.
you can not test application when device is locked
check this apple doc
Your app will be rejected by Apple if you turn app on screen locked.
Refer to these links which answered already:
GameKit keeping connection going while device screen off or in background
Running IOS App with Screen Locked

Resources