Unity, CMock, Ceedling #
https://github.com/ThrowTheSwitch/Unity
Ceedlingのインストール #
$ gem install --install-dir=~/.local ceedling
ceedling new YourNewProjectName
ceedling new –docs MyAwesomeProject
プロジェクトローカルにコピーする #
ceedling new –local YourNewProjectName
ceedling upgrade –local YourNewProjectName
XMLレポートを有効にする #
project.yamlにxml_tests_reportを追加
:plugins:
:load_paths:
- "#{Ceedling.load_path}"
:enabled:
- xml_tests_report
- stdout_pretty_tests_report
- module_generator
xml_tests_reportよりも junit_tets_reportの方がよいだろう これな。Jenkinsで直接読める
- junit_tests_report
Jenkinsにxml_tests_repotrを読み込ませる。 #
(junit_test_reportならこれは必要なし) xUnit plugingをインストールする
unity.xsltをダウンロードする
https://github.com/tmeisenh/jenkins-unity-xml-formatter
ビルド後の処理に、 “Publish xUnit test result report"を追加
Report Typeをカスタムに。
Includes Pattern : build/artifacts/test/report.xml
Custom stylesheet: unity.xls (先ほどダウンロードしてレポジトリーに追加しておく)
ビルドは”シェルの実行”で、”ceedling"でよい。