Question: Tests on a tool with an input of type data_collection
gravatar for yliu41
11 weeks ago by
yliu4150 wrote:

Hello folks,

My Tool#1 is using a data_collection type created by Tool#2 as an input parameter.

<param name="trix_index" 
                label="Specify Trix index" 
                help="Dataset collection containing ix and ixx files generated by UCSC Trix Index Generator"

Below is how the collection is created in Tool#2:

    <collection name="trix_index" type="list" label="Trix index">
        <data name="index_ix" format="txt" from_work_dir="output.ix"/>
        <data name="index_ixx" format="txt" from_work_dir="output.ixx" />

Now, I want to write a test case for my Tool#1. But I am not sure how to specify individual elements "index_ix" and "index_ixx" for data_collection "trix_index" of type "list". I found an example for type "paired" (collection_paired_test.xml and tried the code as below:

<param name="trix_index">
     <collection type="list">
         <element name="index_ix" value="trix_index_files/blast_out.ix" />
         <element name="index_ixx" value="trix_index_files/blast_out.ixx" />

Unfortunately, this didn't work. I got the error:

File "/home/gonramp/.dev/local/lib/python2.7/site-packages/planemo/test/", line 101, in failed_ids
    if test_data["data"]["status"] == "success":
TypeError: 'NoneType' object has no attribute '__getitem__'

Thank you in advance for any hints or suggestions!

ADD COMMENTlink modified 11 weeks ago by Jennifer Hillman Jackson23k • written 11 weeks ago by yliu4150
gravatar for Jennifer Hillman Jackson
11 weeks ago by
United States
Jennifer Hillman Jackson23k wrote:


Try using Planemo for tool development:

These are the areas in the docs that cover data_collections.

Hope that helps! Jen, Galaxy team

ADD COMMENTlink written 11 weeks ago by Jennifer Hillman Jackson23k
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 71 users visited in the last hour