def createTesters(self, dirpath, file, find_only, testroot_params={}): # Build a Parser to parse the objects parser = Parser(self.factory, self.warehouse) # Parse it parser.parse(file, testroot_params.get("root_params", self.root_params)) self.parse_errors.extend(parser.errors) # Retrieve the tests from the warehouse testers = self.warehouse.getActiveObjects() # Augment the Testers with additional information directly from the TestHarness for tester in testers: # Initialize the status system for each tester object immediately after creation tester.initStatusSystem(self.options) self.augmentParameters(file, tester, testroot_params) if testroot_params.get("caveats"): # Show what executable we are using if using a different testroot file tester.addCaveats(testroot_params["caveats"]) # Short circuit this loop if we've only been asked to parse Testers # Note: The warehouse will accumulate all testers in this mode if find_only: self.warehouse.markAllObjectsInactive() return [] # Clear out the testers, we won't need them to stick around in the warehouse self.warehouse.clear() if self.options.enable_recover: testers = self.appendRecoverableTests(testers) return testers
def createTesters(self, dirpath, file, find_only): # Build a Parser to parse the objects parser = Parser(self.factory, self.warehouse) # Parse it parser.parse(file) self.parse_errors.extend(parser.errors) # Retrieve the tests from the warehouse testers = self.warehouse.getActiveObjects() # Augment the Testers with additional information directly from the TestHarness for tester in testers: self.augmentParameters(file, tester) # Short circuit this loop if we've only been asked to parse Testers # Note: The warehouse will accumulate all testers in this mode if find_only: self.warehouse.markAllObjectsInactive() return [] # Clear out the testers, we won't need them to stick around in the warehouse self.warehouse.clear() if self.options.enable_recover: testers = self.appendRecoverableTests(testers) return testers
def createTesters(self, dirpath, file, find_only): # Build a Parser to parse the objects parser = Parser(self.factory, self.warehouse) # Parse it parser.parse(file, self.root_params) self.parse_errors.extend(parser.errors) # Retrieve the tests from the warehouse testers = self.warehouse.getActiveObjects() # Augment the Testers with additional information directly from the TestHarness for tester in testers: self.augmentParameters(file, tester) # Short circuit this loop if we've only been asked to parse Testers # Note: The warehouse will accumulate all testers in this mode if find_only: self.warehouse.markAllObjectsInactive() return [] # Clear out the testers, we won't need them to stick around in the warehouse self.warehouse.clear() if self.options.enable_recover: testers = self.appendRecoverableTests(testers) return testers