Beispiel #1
0
    def discover(self):
        for class_path, lines in groupby(self.rerun_test_file, lambda line: line.rpartition('.')[0]):
            if not class_path:
                # Skip blank lines
                continue
            methods = [line.rpartition('.')[2].strip() for line in lines]

            module_path, _, class_name = class_path.partition(' ')

            klass = test_discovery.import_test_class(module_path, class_name)
            yield klass(name_overrides=methods)
Beispiel #2
0
    def discover(self):
        for class_path, lines in groupby(self.rerun_test_file,
                                         lambda line: line.rpartition('.')[0]):
            if not class_path:
                # Skip blank lines
                continue
            methods = [line.rpartition('.')[2].strip() for line in lines]

            module_path, _, class_name = class_path.partition(' ')

            klass = test_discovery.import_test_class(module_path, class_name)
            yield klass(name_overrides=methods)
    def discover(self):
        finished = False
        first_connect = True
        while not finished:
            class_path, methods, finished = self.get_next_tests(
                retry_limit=(self.retry_limit if first_connect else self.reconnect_retry_limit),
                retry_interval=self.retry_interval,
            )
            first_connect = False
            if class_path and methods:
                module_path, _, class_name = class_path.partition(' ')

                klass = test_discovery.import_test_class(module_path, class_name)
                yield klass(name_overrides=methods)
Beispiel #4
0
    def discover(self):
        finished = False
        first_connect = True
        while not finished:
            class_path, methods, finished = self.get_next_tests(
                retry_limit=(self.retry_limit
                             if first_connect else self.reconnect_retry_limit),
                retry_interval=self.retry_interval,
            )
            first_connect = False
            if class_path and methods:
                module_path, _, class_name = class_path.partition(' ')

                klass = test_discovery.import_test_class(
                    module_path, class_name)
                yield klass(name_overrides=methods)