[CMake] ${CTEST_CONFIGURATION_TYPE} expanded to an empty string while running ctest

Gaetan Lehmann gaetan.lehmann at jouy.inra.fr
Wed Jun 21 15:36:55 EDT 2006


On Wednesday 21 June 2006 21:12, Brad King wrote:
> Gaetan Lehmann wrote:
> > Hi,
> >
> > I'm trying to run a different code some test with different path
> > depending of the configuration (debug, release, ...) with Xcode and
> > cmake 2.4.2
> >
> > I have seen on the mailing list that ${CTEST_CONFIGURATION_TYPE} should
> > be expanded to the configuration type. However, it seem to be expanded
> > to an empty string.
> >
> > ADD_TEST(mytest echo "testing \${CTEST_CONFIGURATION_TYPE}")
> >
> > produce:
> >
> > Start processing tests
> > Test project
> > Constructing a list of tests
> > Done constructing a list of tests
> > Changing directory into
> > /Users/glehmann/src/contrib-itk/WrapITK/build-xcode/Python/Tests
> >   1/ 33 Testing mytest
> > Test command: /bin/echo testing\
> > testing
> > -- Process completed
> >    Passed
> >
> > The following tests passed:
> >         mytest
> >
> > 100% tests passed, 0 tests failed out of 1
> >
> >
> > What is the right way to use configuration type with tests ?
>
> This is correct, but you actually have to specify a configuration type
> when running tests.  Try running the tests like this:
>
> ctest -R mytest -C Debug
>

It works :-)
Would it be possible to use the configuration used for the last build by 
default ?

Thanks

Gaetan

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 191 bytes
Desc: not available
Url : http://public.kitware.com/pipermail/cmake/attachments/20060621/2600f0d8/attachment.pgp


More information about the CMake mailing list