`
sinkzephyr
  • 浏览: 87196 次
  • 性别: Icon_minigender_1
  • 来自: 广州
社区版块
存档分类
最新评论

debugging unit test for iphone-在iphone下调试单元测试

阅读更多
1.在xcode菜单Project->New Customer Executable..
取名如“otest",Path填”Developer/user/bin/otest”



2.右键Executables下新建的otest,选择“Get Info”,在Arguments下

加参数
-SenTest self
UnitTests.octest

UnitTests.octest为单元测试的bundle

再加环境变量
Name Value
DYLD_ROOT_PATH  $(SDKROOT)
DYLD_FRAMEWORK_PATH{BUILD_PRODUCTS_DIR}:${SDK_ROOT}:${DYLD_FRAMEWORK_PATH}
IPHONE_SIMULATOR_ROOT $(SDKROOT)
CFFIXED_USER_HOME $(HOME)/Library/Application Support/iPhone Simulator/User/
OBJC_DISABLE_GC YES
DYLD_LIBRARY_PATH${BUILD_PRODUCTS_DIR}:${SDK_ROOT}:${DYLD_LIBRARY_PATH}
DYLD_NEW_LOCAL_SHARED_REGIONS  YES
DYLD_NO_FIX_PREBINDING  YES




3.debug时选择otest,右键“Start otest With BreakPoint”
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics