Пример #1
0
 def get_runtime_inputs(self, filter_set=['data']):
     label = self.state.get("name", "Input Dataset")
     return dict(input=DataToolParameter(
         None,
         Element("param",
                 name="input",
                 label=label,
                 multiple=True,
                 type="data",
                 format=', '.join(filter_set)), self.trans))
Пример #2
0
 def test_evaluation_of_optional_datasets(self):
     # Make sure optional dataset don't cause evaluation to break and
     # evaluate in cheetah templates as 'None'.
     select_xml = XML('''<param name="input1" type="data" optional="true"></param>''')
     parameter = DataToolParameter(self.tool, select_xml)
     self.job.parameters = [JobParameter(name="input1", value=u'null')]
     self.tool.set_params({"input1": parameter})
     self.tool._command_line = "prog1 --opt_input='${input1}'"
     self._set_compute_environment()
     command_line, extra_filenames, _ = self.evaluator.build()
     self.assertEqual(command_line, "prog1 --opt_input='None'")
Пример #3
0
 def get_runtime_inputs( self, connections=None ):
     return dict( input=DataToolParameter( None, Element( "param", name="input", label=self.label, multiple=False, type="data", format=self.get_filter_set( connections ) ), self.trans ) )