junit_xml.pyi 1.2 KB

1234567891011121314151617181920212223242526272829303132
  1. # Copyright Materialize, Inc. and contributors. All rights reserved.
  2. #
  3. # Use of this software is governed by the Business Source License
  4. # included in the LICENSE file at the root of this repository.
  5. #
  6. # As of the Change Date specified in that file, in accordance with
  7. # the Business Source License, use of this software will be governed
  8. # by the Apache License, Version 2.0.
  9. from typing import TextIO
  10. class TestCase:
  11. errors: list[dict]
  12. failures: list[dict]
  13. skipped: list[dict]
  14. def __init__(
  15. self,
  16. name: str,
  17. classname: str | None = ...,
  18. elapsed_sec: float | None = ...,
  19. allow_multiple_subelements: bool = ...,
  20. ): ...
  21. def add_skipped_info(self, message: str, output: str | None = None) -> None: ...
  22. def add_error_info(self, message: str, output: str | None = None) -> None: ...
  23. def add_failure_info(self, message: str, output: str | None = None) -> None: ...
  24. class TestSuite:
  25. test_cases: list[TestCase]
  26. def __init__(self, name: str, test_cases: list[TestCase] | None = None): ...
  27. def to_xml_report_string(test_suites: list[TestSuite]) -> str: ...
  28. def to_xml_report_file(f: TextIO, test_suites: list[TestSuite]) -> None: ...