# Path: sampletester/testplan.py
# class Wrapper:
# class Environment(Wrapper):
# class Suite(Wrapper):
# class TestCase(Wrapper):
# class Visitor:
# class MultiVisitor(Visitor):
# class Manager:
#   def __init__(self):
#   def update_times(self, starting, ending):
#   def duration(self):
#   def success(self):
#   def selected(self):
#   def __init__(self, env_config, test_suites, env_filter):
#   def name(self):
#   def __init__(self, suite_config, suite_filter, case_filter):
#   def selected(self):
#   def enabled(self):
#   def setup(self):
#   def teardown(self):
#   def name(self):
#   def source(self):
#   def __repr__(self):
#   def __init__(self, test_config, case_filter):
#   def name(self):
#   def spec(self):
#   def __repr__(self):
# def passes_filter(filter: str, name: str):
#   def start_visit(self):
#   def visit_environment(self, environment: Environment, doit: bool):
#   def visit_suite(self, idx: int, suite: Suite, doit: bool):
#   def visit_testcase(self, idx: int, testcase: TestCase, doit: bool):
#   def visit_suite_end(self, idx: int, suite: Suite, doit: bool):
#   def visit_environment_end(self, environment: Environment, doit: bool):
#   def end_visit(self):
#   def __init__(self, *visitors: Visitor):
#   def start_visit(self):
#   def visit_environment(self, environment: Environment, doit: bool, visit_fns):
#   def visit_suite(self, idx: int, suite: Suite, doit: bool, visit_fns):
#   def visit_testcase(self, idx: int, testcase: TestCase, doit: bool,
#                      visit_fns):
#   def visit_suite_end(self, idx: int, suite: Suite, doit: bool, visit_fns):
#   def visit_environment_end(self, environment: Environment, doit: bool,
#                             visit_fns):
#   def end_visit(self):
#   def __init__(self, environment_registry, test_suites, env_filter:str = None):
#   def accept(self, visitor: Visitor):
# def suite_configs_from(test_docs: List[parser.Document]) -> List[object]:
# def suites_from_doc_list(test_docs: List[parser.Document],
#                          suite_filter: str = None,
#                          case_filter: str = None) -> List[Suite]:
# def suites_from(indexed_docs: parser.IndexedDocs,
#                 suite_filter: str = None,
#                 case_filter: str = None) -> List[Suite]:
# SUITE_ENABLED = "enabled"
# SUITE_SETUP = "setup"
# SUITE_TEARDOWN = "teardown"
# SUITE_NAME = "name"
# SUITE_SOURCE = "source"
# SUITE_CASES = "cases"
# CASE_NAME = "name"
# CASE_SPEC = "spec"
# SCHEMA = parser.SchemaDescriptor('test','samples', 1)


from enum import Enum
from sampletester import testplan
import os
import sys
  """Print a (running) summary of test case execution.

  The summary is printed with indentation for environments, suites, and
  test cases. By default, the summary is printed as lines are recorded, unless
  `progress_out == None` is specified in `__init__(...)`. The full output
  accumulated is available via `output()`.
  """

  def __init__(self, verbosity, show_errors,
               progress_out=sys.stderr,
               debug=False):
    self.verbosity = verbosity
    self.show_errors = show_errors
    self.lines = []
    self.indent = '  '
    self.progress_out = progress_out if progress_out else os.devnull
    self.debug = debug

  def visit_environment(self, environment: testplan.Environment, doit: bool):
    if self.verbosity == Detail.NONE and (environment.success() or not self.show_errors):
      return None, None

    name = environment.name()
    status = self.status_str(environment, doit)
    if not status:
      return None, None

    self.append_lines('{}: Test environment: "{}"'.format(status, name))
    return self.visit_suite, None


# Path: sampletester/testplan.py
# class Wrapper:
# class Environment(Wrapper):
# class Suite(Wrapper):
# class TestCase(Wrapper):
# class Visitor:
# class MultiVisitor(Visitor):
# class Manager:
#   def __init__(self):
#   def update_times(self, starting, ending):
#   def duration(self):
#   def success(self):
#   def selected(self):
#   def __init__(self, env_config, test_suites, env_filter):
#   def name(self):
#   def __init__(self, suite_config, suite_filter, case_filter):
#   def selected(self):
#   def enabled(self):
#   def setup(self):
#   def teardown(self):
#   def name(self):
#   def source(self):
#   def __repr__(self):
#   def __init__(self, test_config, case_filter):
#   def name(self):
#   def spec(self):
#   def __repr__(self):
# def passes_filter(filter: str, name: str):
#   def start_visit(self):
#   def visit_environment(self, environment: Environment, doit: bool):
#   def visit_suite(self, idx: int, suite: Suite, doit: bool):
#   def visit_testcase(self, idx: int, testcase: TestCase, doit: bool):
#   def visit_suite_end(self, idx: int, suite: Suite, doit: bool):
#   def visit_environment_end(self, environment: Environment, doit: bool):
#   def end_visit(self):
#   def __init__(self, *visitors: Visitor):
#   def start_visit(self):
#   def visit_environment(self, environment: Environment, doit: bool, visit_fns):
#   def visit_suite(self, idx: int, suite: Suite, doit: bool, visit_fns):
#   def visit_testcase(self, idx: int, testcase: TestCase, doit: bool,
#                      visit_fns):
#   def visit_suite_end(self, idx: int, suite: Suite, doit: bool, visit_fns):
#   def visit_environment_end(self, environment: Environment, doit: bool,
#                             visit_fns):
#   def end_visit(self):
#   def __init__(self, environment_registry, test_suites, env_filter:str = None):
#   def accept(self, visitor: Visitor):
# def suite_configs_from(test_docs: List[parser.Document]) -> List[object]:
# def suites_from_doc_list(test_docs: List[parser.Document],
#                          suite_filter: str = None,
#                          case_filter: str = None) -> List[Suite]:
# def suites_from(indexed_docs: parser.IndexedDocs,
#                 suite_filter: str = None,
#                 case_filter: str = None) -> List[Suite]:
# SUITE_ENABLED = "enabled"
# SUITE_SETUP = "setup"
# SUITE_TEARDOWN = "teardown"
# SUITE_NAME = "name"
# SUITE_SOURCE = "source"
# SUITE_CASES = "cases"
# CASE_NAME = "name"
# CASE_SPEC = "spec"
# SCHEMA = parser.SchemaDescriptor('test','samples', 1)


# Path: sampletester/summary.py
from enum import Enum
from sampletester import testplan
import os
import sys

  """Print a (running) summary of test case execution.

  The summary is printed with indentation for environments, suites, and
  test cases. By default, the summary is printed as lines are recorded, unless
  `progress_out == None` is specified in `__init__(...)`. The full output
  accumulated is available via `output()`.
  """

  def __init__(self, verbosity, show_errors,
               progress_out=sys.stderr,
               debug=False):
    self.verbosity = verbosity
    self.show_errors = show_errors
    self.lines = []
    self.indent = '  '
    self.progress_out = progress_out if progress_out else os.devnull
    self.debug = debug

  def visit_environment(self, environment: testplan.Environment, doit: bool):
    if self.verbosity == Detail.NONE and (environment.success() or not self.show_errors):
      return None, None

    name = environment.name()
    status = self.status_str(environment, doit)
    if not status:
      return None, None

    self.append_lines('{}: Test environment: "{}"'.format(status, name))
    return self.visit_suite, None


  def visit_suite(self, idx, suite: testplan.Suite, doit:bool):