aiida.backends.tests documentation¶
Tests¶
Parser tests¶
Tests for specific subclasses of Data
-
class
aiida.backends.tests.parsers.
TestParsers
(methodName='runTest')[source]¶ This class dynamically finds all tests in a given subfolder, and loads them as different tests.
-
aiida.backends.tests.parsers.
is_valid_folder_name
(name)[source]¶ Return True if the string (that will be the folder name of each subtest) is a valid name for a test function: it should start with
test_
, and contain only letters, digits or underscores.
-
aiida.backends.tests.parsers.
output_test
(pk, testname, skip_uuids_from_inputs=[])[source]¶ This is the function that should be used to create a new test from an existing calculation.
It is possible to simplify the file removing unwanted nodes.
Parameters: - pk – PK of Calculation, used for test
- testname – the name of this test, used to create a new folder. The folder name will be of the form test_PLUGIN_TESTNAME, with PLUGIN substituted by the plugin name, with dots replaced by underscores. Testname can contain only digits, letters and underscores.
- skip_uuids_from_inputs – a list of UUIDs of input nodes to be skipped