iOSアプリ開発でも
Travis CI
2014.03.26 Travis CI Night at EngineYard, K.K.
@nowsprinting/Koji Hasegawa
14年3月27日木曜日
自己紹介
• @nowsprinting/Koji Hasegawa
• フリーランス
(iOS/Androidアプリ受託開発)
• テスト自動化研究会、Androidテスト部
• 著書『iOSアプリ テスト自動化入門』
  『Androidアプリテスト技法』(共著)
14年3月27日木曜日
14年3月27日木曜日
1. テスト自動化への取り組み
2. テストコードの書きかた
3. ユニットテストフレームワーク
4. ユニットテストの補助ツール
5. システムテストの自動化
6. ビルドと配布の自動化
7. CI(継続的インテグレーション)
8. メトリック
iOSアプリ テスト自動化入門 の目次
14年3月27日木曜日
7. CI(継続的インテグレーション)
7.1.OS X Server/Bots
7.2.Jenkins
7.3.Travis CI
iOSアプリ テスト自動化入門 の目次
14年3月27日木曜日
Agenda
• Travis CIでiOSアプリをビルドする設定
• CocoaPodsの利用
14年3月27日木曜日
Travis CIでiOSアプリを
ビルドする設定
14年3月27日木曜日
.travis.yml
language: objective-c
xcode_workspace: HelloTesting.xcworkspace
xcode_scheme: HelloTesting
xcode_sdk: iphonesimulator
14年3月27日木曜日
.travis.yml
language: objective-c
xcode_workspace: HelloTesting.xcworkspace
xcode_scheme: HelloTesting
xcode_sdk: iphonesimulator
Mac OS Xのworkerでビルドされる
xctoolに渡すパラメタ
※script: で直接xcodebuild/xctoolを直接実行も可能
14年3月27日木曜日
CocoaPodsの利用
14年3月27日木曜日
CocoaPodsとは
• Objective-Cのライブラリ管理ツール
• Travis CIのMac OS X workerにはあらかじ
めインストールされている
• “Podfile”がリポジトリにあれば、あとは
よきに計らってくれる
14年3月27日木曜日
14年3月27日木曜日
CocoaPods入れ忘れちゃった (・ω<)
ごめんねつぎ頑張るからごめんね
Ruby 1.9.3を使うか、gem installしてね!
https://github.com/travis-ci/travis-ci/issues/1657
14年3月27日木曜日
• Most Pods now require CocoaPods 0.29, but
we still have 0.28 preinstalled.
• On Ruby 2.0.0, CocoaPods has been seen
crashing with a segmentation fault.
Travis CI: Common Build Problems より
http://docs.travis-ci.com/user/common-build-problems/
14年3月27日木曜日
.travis.yml
language: objective-c
rvm: 1.9.3
before_install:
- gem install cocoapods -v '0.29.0'
xcode_workspace: HelloTesting.xcworkspace
xcode_scheme: HelloTesting
xcode_sdk: iphonesimulator
14年3月27日木曜日
でも、まだJenkinsです…
• ぼっち開発者には厳しい料金設定
※トライアルのように回数制が使いやすい。が、そう
なるとPRのビルドをしなくなるなど(料金のために)
Travis CIの良い所を潰す使いかたをされそうで、定額
のままで良いと思う
• Xcode最新版への対応
• テストやインスペクションの履歴表示
• secret: は知りませんでした
14年3月27日木曜日
ご清聴ありがとうございました
14年3月27日木曜日

iOSアプリ開発でもTravis CI #eytokyo