def _status(bg): """ Create a terse status messages from the overall status of the graph :type bg: `pbsmrtpipe.bgraph.BindingsGraph` :param bg: :return: """ ntasks = len(bg.all_task_type_nodes()) ncompleted_tasks = len(B.get_tasks_by_state(bg, TaskStates.SUCCESSFUL)) return "Workflow status {n}/{t} completed/total tasks".format(t=ntasks, n=ncompleted_tasks)
def test_mock_runner(self): B.resolve_entry_points(self.bgraph, self.EPOINTS_D) state = M.mock_workflow_runner(self.bgraph, {}, self.output_dir, self.workflow_options, self.TASK_OPTIONS, REGISTERED_FILE_TYPES, self.cluster_engine, self.envs) _ = B.get_tasks_by_state(self.bgraph, B.TaskStates.SUCCESSFUL) if state is False: log.debug(B.to_binding_graph_summary(self.bgraph)) self.assertTrue(state)