e3.testsuite.control ==================== .. py:module:: e3.testsuite.control Classes ------- .. autoapisummary:: e3.testsuite.control.TestControlKind e3.testsuite.control.TestControl e3.testsuite.control.TestControlCreator e3.testsuite.control.YAMLTestControlCreator e3.testsuite.control.AdaCoreLegacyTestControlCreator Module Contents --------------- .. py:class:: TestControlKind(*args, **kwds) Bases: :py:obj:`enum.Enum` Control how to run (or not!) testcases. .. py:attribute:: NONE :value: 0 Run the test the regular way. .. py:attribute:: SKIP :value: 1 Do not run the testcase, setting it SKIP. .. py:attribute:: XFAIL :value: 2 Run the test the regular way. If its status is PASS, correct it to XPASS. If it succeeds, correct it to XFAIL. Leave its status unchanged in other cases. .. py:class:: TestControl(message: Optional[str] = None, skip: bool = False, xfail: bool = False) Control the execution and analysis of a testcase. .. py:attribute:: skip :value: False .. py:attribute:: xfail :value: False .. py:attribute:: message :value: None .. py:attribute:: opt_results :type: Optional[Dict[str, Any]] :value: None .. py:class:: TestControlCreator Abstract class to create test controls. .. py:method:: create(driver: e3.testsuite.driver.TestDriver) -> TestControl :abstractmethod: Create a TestControl instance for the given test driver. Raise a ValueError exception if the configuration is invalid. :param driver: Test driver for which we must parse the "control" configuration. .. py:class:: YAMLTestControlCreator(condition_env: Optional[Dict[str, Any]] = None) Bases: :py:obj:`TestControlCreator` Create test controls from "test.yaml"'s "control" entries. .. py:attribute:: condition_env .. py:method:: create(driver: e3.testsuite.driver.TestDriver) -> TestControl Create a TestControl instance for the given test driver. Raise a ValueError exception if the configuration is invalid. :param driver: Test driver for which we must parse the "control" configuration. .. py:class:: AdaCoreLegacyTestControlCreator(system_tags: List[str], opt_filename: str = 'test.opt') Bases: :py:obj:`TestControlCreator` Create test controls for "test.opt"-based legacy AdaCore testsuites. .. py:method:: default_script(driver: e3.testsuite.driver.TestDriver) -> str Return the default test script filename. :param driver: Test driver for which we must parse the "control" configuration. .. py:method:: default_opt_results(driver: e3.testsuite.driver.TestDriver) -> Dict[str, Optional[str]] Return the default options. test.opt files can override these. By default, a test is not DEAD, SKIP, nor XFAIL. Its execution timeout is 780 seconds. Test script is "test.cmd" and its output is compared against "test.out". :param driver: Test driver for which we must parse the "control" configuration. .. py:attribute:: opt_filename :value: 'test.opt' .. py:attribute:: system_tags .. py:method:: create(driver: e3.testsuite.driver.TestDriver) -> TestControl Create a TestControl instance for the given test driver. Raise a ValueError exception if the configuration is invalid. :param driver: Test driver for which we must parse the "control" configuration.