def setUp(self): self.setup_app() job = Job() job.id = 345 job.tool_id = TEST_TOOL_ID job.user = User() self.model_objects = {Job: {345: job}} self.app.model.context = MockContext(self.model_objects) self.app.toolbox = MockToolbox(MockTool(self)) self.working_directory = os.path.join(self.test_directory, "working") self.app.object_store = MockObjectStore(self.working_directory) self.queue = MockJobQueue(self.app) self.job = job
def setUp(self): self.setup_app() self.tool = MockTool(self.app) self.job = Job() self.job.history = History() self.job.parameters = [JobParameter(name="thresh", value="4")] self.evaluator = ToolEvaluator(self.app, self.tool, self.job, self.test_directory)
def setUp(self): self.tool = Bunch( stdio_regexes=[], stdio_exit_codes=[], ) self.job = Job() self.job.id = "test_id" self.stdout = '' self.stderr = '' self.tool_exit_code = None
def job(app: FileSourcesMockApp) -> Job: job = Job() app.model.session.add(job) app.model.session.flush() return job