Hi all,

In the past few months some additional semantic checks were added into
CPackComponentsForAll test - in particularly into IgnoreGroup test.

Now it's becoming harder to add new tests there as each test requires
somewhat different package content and variable settings. It is also
getting harder to see which part of package creation is actually
required for which package validation at the end.

Because of the reasons above there are less CPackRPM tests than I'd
like to see so I've decided to create new tests for testing CPack.

The requirements that I know of are:
1) Each test should provide its own recipe on how to create packages
(the way it is done for executing CMake in RunCMake tests - with cmake
script for each test)

2) Each test should provide a verify results script that terminates
with FATAL_ERROR message on failure (maybe also printing out actual
output and for RPM also generated spec file or some other relevant
data for fixing tests that fail on nightly build servers) - this
script differs from regex and return code tests in RunCMake as it has
to execute different package query commands (or maybe unpack a
generated archive) to get the result for comparison

3) Running the tests should first execute CMake, then CPack and at the
end verify the result (first two steps are covered in
RunCMake.CPackRPM test)

4) Tests should be listed as in RunCMake RunCMakeTest.cmake scripts

5) Each test should also specify for which CPack generators should a
test be executed (this would require one verify result script per
generator per test)

6) Each test should also specify a list of expected generated files
(and maybe intermediate files as RPM spec files) for automatic
validation of expected output

This would be most useful for RPM and DEB packages validation,
somewhat useful for archive generators and less useful for NSIS and
other GUI installer generators (not sure how to test those other than
check that installer file was generated...).

I've managed to add CPackRPM test to RunCMake even though it requires
first execution of CMake and afterwards also execution of CPack but
I'm not certain that trying to squeeze the tests described above into
RunCMake is the right way to go.

So now I have two questions...

Would it be OK if I add something like CPackSemanticTests (I'm bad
with names) into Tests directory and implement it similarly to
RunCMake tests?

Does anybody have additional ideas on how to extend/improve the list
of requirements written above (e.g. with steps to validate GUI
installer packages or simplify the tests so that there would be less
work involved in adding new ones)?

Thanks,
Domen
-- 

Powered by www.kitware.com

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

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

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

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers

Reply via email to