qubes-installer-qubes-os/anaconda/tests
Marek Marczykowski-Górecki 6bc5671491
anaconda: update to 25.20.9-1
Apply:
  git diff --full-index --binary anaconda-23.19.10-1..anaconda-25.20.9-1

And resolve conflicts.

QubesOS/qubes-issues#2574
2017-02-14 02:36:20 +01:00
..
cppcheck anaconda: update to 21.48.21-1 2016-03-22 02:27:15 +13:00
dd_tests anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
dracut_tests anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
gettext_tests anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
glade anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
gui anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
install anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
kickstart_test Update anaconda to 20.25.16 2014-04-08 05:50:31 +02:00
lib anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
logpicker_test Update anaconda to 20.25.16 2014-04-08 05:50:31 +02:00
mock Update anaconda to 20.25.16 2014-04-08 05:50:31 +02:00
pyanaconda_test Update anaconda to 20.25.16 2014-04-08 05:50:31 +02:00
pyanaconda_tests anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
pylint anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
regex Update anaconda to 20.25.16 2014-04-08 05:50:31 +02:00
regex_tests anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
storage anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
storage_test Update anaconda to 20.25.16 2014-04-08 05:50:31 +02:00
__init__.py anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
Makefile.am anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
Makefile.in anaconda: import unmodified 18.37.11 version from fc18 2013-01-24 01:45:53 +01:00
nosetests_root.sh anaconda: Update to 23.19.10 2016-04-10 00:00:00 -04:00
nosetests.sh anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
README.rst anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
run_gui_tests.sh anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
testenv.sh anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00
usercustomize.py anaconda: update to 25.20.9-1 2017-02-14 02:36:20 +01:00

Testing Anaconda
================

Before testing Anaconda you need to install all required dependencies,
prepare the environment and build the sources::

    make -f Makefile.am install-test-requires
    ./autogen.sh
    ./configure
    make

Executing the tests can be done with::

    make check

To run a single test do::

    make TESTS=install/run_install_test.sh check

See `tests/Makefile.am` for possible values. Alternatively you can try::

    make ci

This has the advantage of producing Python test coverage for all tests.
In case the *ci* target fails there is also a *coverage-report* target
which can be used to combine the multiple `.coverage` files into one and
produce a human readable report.

.. NOTE::

    When using the `ci' target you need to use a regular user account which
    is a member of the `mock' group. You can update your account by running
    the command::

        # usermod -a -G mock <username>

    Your regular user account also needs to execute `sudo' because some tests
    require root privileges!

Test Suite Architecture
------------------------

Anaconda has a complex test suite structure where each top-level directory
represents a different class of tests. They are

- *cppcheck/* - static C/C++ code analysis using the *cppcheck* tool;
- *dd_tests/* - Python unit tests for driver disk utilities (utils/dd);
- *dracut_tests/* - Python unit tests for the dracut hooks used to configure the
  installation environment and load Anaconda;
- *gettext/* - sanity tests of files used for translation; Written in Python and
  Bash;
- *glade/* - sanity tests for .glade files. Written in Python;
- *gui/* - specialized test suite for the graphical interface of anaconda. This
  is written in Python and uses the `dogtail <https://fedorahosted.org/dogtail/>`_
  accessibility module. All tests are executed using ./anaconda.py from the local
  directory;
- *install/* - basic RPM sanity test. Checks if anaconda.rpm can be installed in
  a temporary directory without failing dependencies or other RPM issues;
- *lib/* - helper modules used during testing;
- *pyanaconda_tests/* - unit tests for the :mod:`pyanaconda` module;
- *pylint/* - checks the validity of Python source code using the *pocketlint*
  tool;
- *regex_tests/* - Python unit tests for regular expressions defined in
  :mod:`pyanaconda.regexes`;
- *storage/* - test cases used to verify partitioning scenarios for success or
  expected failures. The scenarios are described using kickstart snippets.
  Written in Python with a custom test case framework based on
  `blivet <https://github.com/rhinstaller/blivet>`_;



.. NOTE::

    All Python unit tests inherit from the standard :class:`unittest.TestCase`
    class unless specified otherwise!

    Some tests require root privileges and will be skipped if running as regular
    user!