4
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

catkinでユニットテスト走らせるときは、まずcatkin_make run_tests

Posted at

gtest - ROS Wikiを読んでも"Building and running tests"の内容が中途半端でハマったのでメモ。
ROS Wiki通りに進んで行くと"Simple makeの後にmake testで動く"ようなことが書いてあるが、テストコードがビルドされずにテスト出来ない状態に陥った。(もしかしたら、設定が悪いのかも?)

そんな時、catkin_make run_tests と catkin_make test の違いを発見。この記事によれば、

cppのテスト(gtest)を使う場合,テストコードを初回ビルドするのにこちらが必須.

とのこと。(なんと・・・)

catkin_make run_testsしたら意図通り(&他のサンプル通り)にgtestが動いた。

4
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?