Yi, Yes, it is totally fine to ask questions like this. To answer your question, unfortunately, there is a weakness in the testing framework that limits the way repeat elements can be tested, but I believe the testing you want to do can be done. The only way to test a tool with a repeat element is with a test that includes exactly one _set_ for each repeat. (When you run the tool, you could include 0, 1, or more than 1 sets, but you can only test with 1.) In your case, you have a repeat element that requires two files, as follows: <repeat name="replicates" title="Replicate"> <param name="tfile" type="data" label="Treatment file"/> <param name="cfile" type="data" label="Control file"/> </repeat> So your test should include something like: <test> ... <param name="tfile" value="ma2c_treatment_ce4.pair" /> <param name="cfile" value="controlfile.name" /> ... </test> Both files need to be included and only one pair (set) can be. The parameter names in the test should exactly match the names in the input parameter declaration. Note that the syntax for the command line should refer to the repeat items something like this: #for $r in $replicates ${r.tfile} ${r.cfile} #end for If you want to see a simple example, tools/filters/sorter.xml has a fairly complex repeat element with multiple items and tests that run. Let us know if you have any other questions. Regards, Kelly On Oct 18, 2010, at 11:39 AM, WANGYi wrote:
Hi,
Our team is now testing our integrated tools under galaxy testing framework.
At present, we are trying to test the '<repeat>' elements in one of our tools, e.g. <repeat name="replicates" title="Replicate"> <param name="tfile" type="data" label="Treatment file"/> <param name="cfile" type="data" label="Control file"/> </repeat>
we tried add the following section into the <test> tag and ran the test, but did not make it. <test> <param name="tfile" value="ma2c_treatment_ce4.pair" /> <param name="tfile" value="ma2c_treatment_ce5.pair" /> </test>
after searching all over the internet, we were not able to come up with any solution (maybe we missed).
I dont know if it proper to ask you a question like this. but we are kinda desprated for this issue. Could you please kindly tell us, how to write the test section when there are two or more 'replicates' inputed?
Appreciate so much.
Regards Yi _______________________________________________ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev