def test_repeat_evaluation(self): repeat = Repeat() repeat.name = "r" repeat.inputs = {"thresh": self.tool.test_thresh_param()} self.tool.set_params({"r": repeat}) self.job.parameters = [JobParameter(name="r", value='''[{"thresh": 4, "__index__": 0},{"thresh": 5, "__index__": 1}]''')] self.tool._command_line = "prog1 #for $r_i in $r # $r_i.thresh#end for#" self._set_compute_environment() command_line, extra_filenames, _ = self.evaluator.build() self.assertEqual(command_line, "prog1 4 5")
def test_repeat_evaluation( self ): repeat = Repeat() repeat.name = "r" repeat.inputs = { "thresh": self.tool.test_thresh_param() } self.tool.set_params( { "r": repeat } ) self.job.parameters = [ JobParameter( name="r", value='''[{"thresh": 4, "__index__": 0},{"thresh": 5, "__index__": 1}]''' ) ] self.tool._command_line = "prog1 #for $r_i in $r # $r_i.thresh#end for#" self._set_compute_environment() command_line, extra_filenames, _ = self.evaluator.build( ) self.assertEquals( command_line, "prog1 4 5" )