cwltest.plugin ============== .. py:module:: cwltest.plugin .. autoapi-nested-parse:: Discovers CWL test files and converts them to pytest.Items. Exceptions ---------- .. autoapisummary:: cwltest.plugin.CWLTestException Classes ------- .. autoapisummary:: cwltest.plugin.TestRunner cwltest.plugin.CWLItem cwltest.plugin.CWLYamlFile Functions --------- .. autoapisummary:: cwltest.plugin.pytest_addoption cwltest.plugin.pytest_collect_file cwltest.plugin.pytest_configure cwltest.plugin.pytest_sessionfinish cwltest.plugin.pytest_addhooks Module Contents --------------- .. py:class:: TestRunner Bases: :py:obj:`Protocol` .. autoapi-inheritance-diagram:: cwltest.plugin.TestRunner :parts: 1 Protocol to type-check test runner functions via the pluggy hook. .. py:method:: __call__(config, processfile, jobfile) Type signature for pytest_cwl_execute_test hook results. .. py:exception:: CWLTestException Bases: :py:obj:`Exception` .. autoapi-inheritance-diagram:: cwltest.plugin.CWLTestException :parts: 1 custom exception for error reporting. .. py:class:: CWLItem(name, parent, spec) Bases: :py:obj:`pytest.Item` .. autoapi-inheritance-diagram:: cwltest.plugin.CWLItem :parts: 1 A CWL test Item. .. py:attribute:: spec .. py:method:: runtest() Execute using cwltest. .. py:method:: repr_failure(excinfo, style = None) Document failure reason. Called when self.runtest() raises an exception. .. py:method:: reportinfo() Status report. .. py:class:: CWLYamlFile(fspath = None, path_or_parent = None, path = None, name = None, parent = None, config = None, session = None, nodeid = None) Bases: :py:obj:`pytest.File` .. autoapi-inheritance-diagram:: cwltest.plugin.CWLYamlFile :parts: 1 A CWL test file. .. py:method:: collect() Load the cwltest file and yield parsed entries. .. py:function:: pytest_addoption(parser) Add our options to the pytest command line. .. py:function:: pytest_collect_file(file_path, parent) Is this file for us. .. py:function:: pytest_configure(config) Store the raw tests and the test results. .. py:function:: pytest_sessionfinish(session) Generate badges. .. py:function:: pytest_addhooks(pluginmanager) Register our cwl hooks.