Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Running xcode iOS simulator build

I developed an iOS app with Facebook integration. I need to send an iOS simulator build for Facebook to review how the Facebook integration works on my app.

The link provides the instructions on how to create the iOS Simulator build. https://developers.facebook.com/docs/ios/creating-ios-simulator-build-for-review/

The said link provides code that creates the iOS simulator build

xcodebuild -arch i386 -sdk iphonesimulator{version}

What I wanted to do is to run the app iOS Simulator Build. I want to test if iOS simulator build works.

I searched and found this:

Launch an iOS app in the simulator without XCode

which asked me to use this code to run the iOS simulator build.

/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone\ Simulator.app/Contents/MacOS/iPhone\ Simulator -SimulateApplication ${PROJECT}/build/Debug-iphonesimulator/<yourapp>.app/<yourapp>

Yes, the iOS simulator runs however it does not launch my app.

How should I run the iOS simulator build on the simulator? Need help on this. Thanks!

Addition Note: I am using Xcode 5.1.1

like image 278
user3667354 Avatar asked May 23 '14 03:05

user3667354


People also ask

How do I run Xcode in simulator?

Open Xcode and click Menu > Xcode > Preferences > Select Components, and then choose the simulator version you want to download. When a simulator is opened from AppStudio, AppStudio Player automatically installs (if necessary) and opens in it.

Can I run an iOS app on a simulator?

After you create a project, you can build and run your app on a simulated or real device without needing to lay out the user interface or write code. You may connect a real device to your Mac using a cable, or for iOS or tvOS apps, connect it over Wi-Fi after you pair it with Xcode.

How do I run Xcode simulator on Mac?

To launch a Simulator without running an appChoose Xcode > Open Developer Tool > Simulator. Control-click the Xcode icon in the Dock, and from the shortcut menu, choose Open Developer Tool > Simulator.


2 Answers

I had success using ios-sim. Then run with ios-sim launch <yourproject>.app

like image 182
vish Avatar answered Oct 07 '22 08:10

vish


Update instructions for Xcode 6.x and later using simctl:

xcrun simctl install booted /path/to/your/built/simulator.app
xcrun simctl launch booted com.your.app.identifier
like image 45
Jeremy Huddleston Sequoia Avatar answered Oct 07 '22 08:10

Jeremy Huddleston Sequoia