pungi/doc/testing.rst

43 lines
864 B
ReStructuredText
Raw Normal View History

===============
Testing Pungi
===============
Test Data
=========
Tests require test data and not all of it is available in git.
2015-07-02 13:15:27 +00:00
You must create test repositories before running the tests::
2015-07-02 13:15:27 +00:00
make test-data
Requirements: createrepo_c, rpmbuild
Unit Tests
==========
Unit tests cover functionality of Pungi python modules.
2015-07-02 13:15:27 +00:00
You can run all of them at once::
2015-07-02 13:15:27 +00:00
make test
2015-07-02 13:15:27 +00:00
which is shortcut to::
2015-07-02 13:15:27 +00:00
python2 setup.py test
python3 setup.py test
2015-07-02 13:15:27 +00:00
You can alternatively run individual tests::
2015-07-02 13:15:27 +00:00
cd tests
./<test>.py [<class>[.<test>]]
Functional Tests
================
Because compose is quite complex process and not everything is covered with
unit tests yet, the easiest way how to test if your changes did not break
anything badly is to start a compose on a relatively small and well defined
2015-07-02 13:15:27 +00:00
package set::
2015-07-02 13:15:27 +00:00
cd tests
./test_compose.sh