iOS 中的单元测试与持续集成

Unit Test 工具

1、OCUnit:从 xcode 2.1 开始集成到开发环境中,使用方便,不需要引入额外的库。并可以配置 xcodebuild,实现在命令行测试,从而在 CI 中进行测试与报告。

2、GTM 的单元测试部分:对 OCUnit 进行了扩展,增加了一些宏。地址:https://code.google.com/p/google-toolbox-for-mac/wiki/iPhoneUnitTesting

3、GHUnit:带有一个独立的 GUI。地址:https://github.com/gabriel/gh-unit

4、CATCH:C++ Adaptive Test Cases in Headers,是一个比较新的框架,地址:https://github.com/philsquared/Catch

5、OCMock:地址:http://ocmock.org/

CI 工具

1、Hudson

2、Jenkins

3、CruiseControl

说明:单元测试建议用 OCUnit,持续集成建议用 Jenkins。

原文地址:https://www.cnblogs.com/Proteas/p/2649331.html