Question

I'm learning about automated iOS testing methods and right now I'm trying Frank. I've written small simple app and added Frank to it. The problem is - I can't get it to work at all. I've gone through the tutorials and various "Getting started" guides - everything seems to be OK, I've run

frank setup

Goes fine. All the folders and stuff are created

frank build

OK. "Frankified" build appears.

frank launch

It launches the simulator with the app open. But I can't do anything else.

frank inspect

Opens localhost:37265 with "could not connect" message. When I run

cucumber

Starts the simulator, begin to run features, but the first one, device rotation gets PING FAILED!!! message:

Feature: As an iOS developer
I want to have a sample feature file

So I can see what my next step is in the wonderful world of Frank/Cucumber testing

Scenario: # features/my_first.feature:6

  Rotating the simulator for demonstration purposes

PING FAILED!!!!!!!!!!!!!

I've checked and re-checked accessibility, re-installed Frank. Tried to add it to new, empty app - all the same. It can launch it, but it can't do anything else.

Using xcode 5, iOS7 and OS X 10.8.4

I can't find what I'm missing here

Was it helpful?

Solution

Looks like I found the solution (in more old tutorials). I don't know why official tutorial doesn't contain these steps, but it didn't work without them for me.

  1. Run "frank setup" inside project folder in the console to create Frank folder with all the stuff needed
  2. In your xCode project, create new target. It's necessary , because we'll add some frameworks which are not needed in you distribution version.
  3. Add all *.a files from Frank folder to your new frank target (obviously, if you making an app for iOS, you don't need libraries for Mac. It's easy to identify them by "Mac" word in the name) Frameworks
  4. Add "-all_load" and "-ObjC" flags to "Other linker flags" in you xCode project "Build settings" Build settings
  5. Run "frank build --target [your_target_name]" inside project folder in the console
  6. Run "frank launch" + "frank inspect" You should go to localhost:37265 where Symbiote will display your app
  7. Go to "Frank" folder inside your project, run "cucumber" to launch tests

If you want to debug fankified app through xCode, you must go to "Manage schemes" and select proper executable for you frank target.

Scheme preferences

Than you can launch frankified app with tests just as usual one (Cmd+R) and see all the debug lines inside xCode console

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top