Testing Framework#
Note
This page explains skbase’s testing framework with an emphasis on how
the package’s developers are expected to interact with the test suite. If
you are developer and want to learn how you can use the skbase
testing framework to develop your own package, see our
testing user guide.
skbase uses pytest to verify code is working as expected.
This page gives an overview of the tests, an introduction on adding new tests,
and how to extend the testing framework.
Warning
This page is under construction. We plan to add more tests and increased documentation on the testing framework in an upcoming release.
Test module architecture#
skbase uses a tiered approach to test its functionality:
package level tests in
tests/test_base.pyare designed to verify theBaseObjectinterfacemodule level tests are focused on verifying the compliance of a concrete
low level tests in the
testsfolders in each module are used to verify the functionality of individual code artifacts
Module conventions are as follows:
- Each module contains a
testsfolder that contains tests specific to that module. Sub-modules may also contain
testsfolders.module tests focused on testing a specific class interface should contain a file
test_all_[name_of_class].py
- Each module contains a
testsfolders may contain_config.pyfiles to collect test configuration settings for that modulesmodule and low level tests should not repeat tests performed at a higher level