I'm using background audio mode in my app to play music, but when the track list skips between tracks the app is shut down. My problem with tracking this bug is that when I run the app in debug mode with Xcode connected the app will stay in foreground forever! Is there a way to tell Xcode to let the app enter it's background mode with Xcode connected in debug mode?
3
-
Just tap on Home button of the device it will send the app in background mode and you can debug too.iphonic– iphonic2016-12-25 19:51:20 +00:00Commented Dec 25, 2016 at 19:51
-
Run the app in debug mode and send the app to background with the Home button. Any breakpoint or crash will be shown in Xcode.GoRoS– GoRoS2016-12-25 19:51:28 +00:00Commented Dec 25, 2016 at 19:51
-
Thanks for your answers -IHecot– Hecot2016-12-25 23:41:50 +00:00Commented Dec 25, 2016 at 23:41
Add a comment
|
1 Answer
To simulate a background fetch, launch your app and then go to Xcode and choose Debug > Simulate Background Fetch.
You can also configure a scheme to control how Xcode launches your app. To enable your app to be launched directly into a suspended state, choose Product > Scheme > Edit Scheme and select the Background Fetch checkbox.
1 Comment
Hecot
Thanks - this was what I'm looking for but haven't seen it! THANKS!
