View Issue Details

IDProjectCategoryView StatusLast Update
0002220Slicer4Core: Building (CMake, Superbuild)public2012-08-21 09:47
Reporternicole Assigned Tojcfr  
PrioritynormalSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Product Version 
Target VersionSlicer 4.2.0Fixed in VersionSlicer 4.2.0 
Summary0002220: Module wizard for loadable modules - problem with Testing/Cxx/CMakeLists.txt
Description

Using the module wizard to create a new loadable module, it creates
Modules/Loadable/MyModule/Testing/Cxx/CMakeLists.txt
I add new test files to the create_test_sourcelist variable and compile, but they're not discovered as tests via:
ctest -R MyModule -N
only the generic module tests are discovered. The binary is built and I can run it manually, and it does show my new tests, but I'd like to be able to access the tests via ctest.

Additional Information

I put a status message inside the foreach loop at the end of the file that loops over ${KIT_TEST_NAMES} to call the SIMPLE_TEST macro, and I'm not seeing any output.

TagsNo tags attached.

Activities

jcfr

jcfr

2012-06-21 00:09

administrator   ~0004893

Consider reading these two comments [1] and [2]

Step1: Add source of the test to the source list
Step2: add the test using SIMPLE_TEST macro

[1] https://github.com/Slicer/Slicer/blob/master/Extensions/Testing/LoadableExtensionTemplate/Testing/Cxx/CMakeLists.txt#L13
[2] https://github.com/Slicer/Slicer/blob/master/Extensions/Testing/LoadableExtensionTemplate/Testing/Cxx/CMakeLists.txt#L28

nicole

nicole

2012-06-21 05:33

administrator   ~0004894

Those comments didn't appear in the generated CMakeLists.txt file in my new loadable module. I did as the first comment suggested, but it's really unclear that adding to the variable that's being looped over for the SIMPLE_TEST calls isn't enough to get the tests added. I'd request that the comments get transfered to the output module file, or that an explicit test is added. If using the first option, the last comment should also be changed from

Using SIMPLE_TEST(), you could add your test after this line.

to

Add your test after this line, using SIMPLE_TEST( ${testname} )

since it won't be added properly otherwise.

jcfr

jcfr

2012-06-21 08:21

administrator   ~0004895

Fixed in r20449
See http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=20449

jcfr

jcfr

2012-07-27 15:40

administrator   ~0005401

Dear issue reporter,

Good news :) Slicer developers SOLVED the problem you reported - YOU now need to VERIFY and CLOSE this issue.

Issue History

Date Modified Username Field Change
2012-06-19 11:04 nicole New Issue
2012-06-19 11:04 nicole Status new => assigned
2012-06-19 11:04 nicole Assigned To => jcfr
2012-06-21 00:09 jcfr Note Added: 0004893
2012-06-21 00:09 jcfr Status assigned => resolved
2012-06-21 00:09 jcfr Fixed in Version => Slicer 4.1.2 - July 1st 2012
2012-06-21 00:09 jcfr Resolution open => fixed
2012-06-21 00:10 jcfr Resolution fixed => no change required
2012-06-21 05:33 nicole Note Added: 0004894
2012-06-21 05:33 nicole Status resolved => assigned
2012-06-21 05:33 nicole Resolution no change required => reopened
2012-06-21 08:21 jcfr Note Added: 0004895
2012-06-21 08:21 jcfr Status assigned => resolved
2012-06-21 08:21 jcfr Resolution reopened => fixed
2012-07-27 15:40 jcfr Note Added: 0005401
2012-07-30 09:21 nicole Status resolved => closed
2012-08-21 09:45 jcfr Fixed in Version Slicer 4.1.2 - August => Slicer 4.2.0 - Feature freeze Sept 1st 2012
2012-08-21 09:47 jcfr Target Version => Slicer 4.2.0 - Feature freeze Sept 1st 2012