Hi,

I cannot get add_test to work as documented.

  add_test(mytest MyExe)

correctly runs MyExe. However, if I try to use any of the "generator expressions" (such as $<CONFIGURATION>), it fails:

  add_test(mytest ${SOMEVARIABLE}/$<CONFIGURATION>/MyExe)

fails to locate MyExe correctly, since it isn't expanding $<CONFIGURATION> correctly.

Looked in the following places:
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/Release/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/Release/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/Debug/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/Debug/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/MinSizeRel/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/MinSizeRel/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/RelWithDebInfo/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/RelWithDebInfo/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/Deployment/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/Deployment/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/Development/TestIDE
/home/jesperes/dev/tooticki/core/ide/../stage/$<CONFIGURATION>/common/bin/Development/TestIDE

Also, the form

  add_test(NAME mytest COMMAND MyCommand)

doesn't work at all. No tests are generated, and "make test" complains that there aren't any tests.

What am I doing wrong?

I'm using CMake 2.8.2.

--
/Jesper

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to