ios - How could I launch non-hosted test in Xcode 7.3? -


i have unit test (not ui tests) , launching app along tests undesirable. read so-called non-hosted tests , sounds suitable here. however, trying launch non-hosted test on xcode 7.3 faced 1 serious problem - complains classes in app being tested couldn't found linker.

what have read , tried:

app delegate substitution based on launch arguments - undesirable since forces app know tests (tight coupling, broken encapsulation etc...) , launch app along test (even though doing nothing)

xcode 5 unit testing: starts app - tried every answer here , don't work except changing classes target membership not option since changing target membership manually error-proned , becomes difficult when project grows

apple's outdated guide - nope

xcode test target host application forces wrong target build section of scheme - nope

https://stackoverflow.com/a/22024428/2305175 - nope

manually creating unit test target explicitly setting target tested none - nope

how run non-hosted tests without changing classes target membership, app delegate substitution , other questionable techniques???

you can achieve using xctool xcode 7

  1. first go test target settings.
  2. go general tab
  3. select none host application
  4. then install xctool terminal
  5. run tests terminal follows,

    xctool -workspace test.xcworkspace -scheme testscheme run-tests -sdk iphonesimulator


Comments

Popular posts from this blog

html - Styling progress bar with inline style -

java - Oracle Sql developer error: could not install some modules -

How to use autoclose brackets in Jupyter notebook? -