changeset 1:854b7c026a7e draft default tip

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/deeparg commit 8b3c2a9c92770c45257d95585facba365633718e
author iuc
date Fri, 27 Jun 2025 12:41:25 +0000
parents 558018b49a4c
children
files deeparg_short_reads.xml macros.xml
diffstat 2 files changed, 84 insertions(+), 10 deletions(-) [+]
line wrap: on
line diff
--- a/deeparg_short_reads.xml	Fri Feb 14 11:10:12 2025 +0000
+++ b/deeparg_short_reads.xml	Fri Jun 27 12:41:25 2025 +0000
@@ -18,10 +18,17 @@
 #end if
 ##
     mkdir -p deeparg_short_reads_output &&
-    #set $extension = str($forward_pe_file.ext)
-    ln -s -f '${forward_pe_file}' 'input_forward.${extension}' &&
-    #set $extension = str($reverse_pe_file.ext)
-    ln -s -f '${reverse_pe_file}' 'input_reverse.${extension}' &&
+    #if $input_option.choice == 'paired'
+        #set $extension = str($input_option.fastq_input1.ext)
+        ln -s -f '${input_option.fastq_input1}' 'input_forward.${extension}' &&
+        #set $extension = str($input_option.fastq_input2.ext)
+        ln -s -f '${input_option.fastq_input2}' 'input_reverse.${extension}' &&
+    #else if $input_option.choice == 'paired_collection'
+        #set $extension = str($input_option.pair_input.forward.ext)
+        ln -s -f '${input_option.pair_input.forward}' 'input_forward.${extension}' &&
+        #set $extension = str($input_option.pair_input.reverse.ext)
+        ln -s -f '${input_option.pair_input.reverse}' 'input_reverse.${extension}' &&
+    #end if
     deeparg short_reads_pipeline
         --forward_pe_file 'input_forward.${extension}'
         --reverse_pe_file 'input_reverse.${extension}'
@@ -37,8 +44,19 @@
         <!-- used only for tests, as the deeparg database contains large files that cannot be deleted or reduced. -->
         <param name="hide_db_build" type="hidden" value=""/>
         <!-- -->
-        <param argument="--forward_pe_file" type="data" format="fasta,fasta.gz,fastqsanger,fastqsanger.gz" label="Forward mate from paired end library"/>
-        <param argument="--reverse_pe_file" type="data" format="fasta,fasta.gz,fastqsanger,fastqsanger.gz" label="Reverse mate from paired end library"/>
+        <conditional name="input_option">
+            <param name="choice" type="select" label="Select your input option">
+                <option value="paired" selected="true">Paired-end</option>
+                <option value="paired_collection">Paired-end collection</option>
+            </param>
+            <when value="paired">
+                <param name="fastq_input1" argument="--forward_pe_file" type="data" format="fasta,fasta.gz,fastqsanger,fastqsanger.gz" label="Forward mate from paired end library"/>
+                <param name="fastq_input2" argument="--reverse_pe_file" type="data" format="fasta,fasta.gz,fastqsanger,fastqsanger.gz" label="Reverse mate from paired end library"/>
+            </when>
+            <when value="paired_collection">
+                <param name="pair_input" type="data_collection" format="fastq,fastqsanger,fasta,fastq.gz,fastqsanger.gz" collection_type="paired" label="Select a paired collection"/>
+            </when>
+        </conditional>
         <param name="deeparg_db" type="select" label="DeepARG database">
             <options from_data_table="deeparg">
                 <filter type="static_value" value="@TOOL_VERSION@" column="db_version"/>
@@ -88,11 +106,14 @@
         </data>
     </outputs>
     <tests>
-        <!-- Test 1 -->
+        <!-- Test 1 Paired -->
         <test expect_num_outputs="6">
             <param name="hide_db_build" value="true"/>
-            <param name="forward_pe_file" value="light_F.fq.gz" ftype="fastqsanger.gz"/>
-            <param name="reverse_pe_file" value="light_R.fq.gz" ftype="fastqsanger.gz"/>
+            <conditional name="input_option">
+                <param name="choice" value="paired"/>
+                <param name="fastq_input1" value="light_F.fq.gz" ftype="fastqsanger.gz"/>
+                <param name="fastq_input2" value="light_R.fq.gz" ftype="fastqsanger.gz"/>
+            </conditional>
             <param name="deeparg_db" value="deeparg_1.0.4-19122024"/>
             <section name="output_files">
                 <param name="output_selection" value="file_ARG_tsv,file_merged_ARG_tsv,file_ARG_subtype_tsv,file_ARG_type_tsv,file_potential_ARG_tsv,file_all_hits_tsv"/>
@@ -134,6 +155,59 @@
                 </assert_contents>
             </output>
         </test>
+        <!-- Test 2 Paired collection -->
+        <test expect_num_outputs="6">
+            <param name="hide_db_build" value="true"/>
+            <conditional name="input_option">
+                <param name="choice" value="paired_collection"/>
+                <param name="pair_input">
+                    <collection type="paired">
+                        <element name="forward" value="light_F.fq.gz" ftype="fastqsanger.gz"/>
+                        <element name="reverse" value="light_R.fq.gz" ftype="fastqsanger.gz"/>
+                    </collection>
+                </param>
+            </conditional>            
+            <param name="deeparg_db" value="deeparg_1.0.4-19122024"/>
+            <section name="output_files">
+                <param name="output_selection" value="file_ARG_tsv,file_merged_ARG_tsv,file_ARG_subtype_tsv,file_ARG_type_tsv,file_potential_ARG_tsv,file_all_hits_tsv"/>
+            </section>
+            <output name="output_mapping_ARG" ftype="tabular">
+                <assert_contents>
+                    <has_text text="BAE06008.1|FEATURES|mexQ|multidrug|mexQ"/>
+                    <has_text text="CATA"/>
+                </assert_contents>
+            </output>
+            <output name="output_merged_ARG" ftype="tabular">
+                <assert_contents>
+                    <has_line line="ACRB&#9;568&#9;600&#9;1&#9;multidrug"/>
+                    <has_text text="VANR&#9;137&#9;169&#9;1&#9;glycopeptide"/>
+                </assert_contents>
+            </output>
+            <output name="output_subtype_ARG" ftype="tabular">
+                <assert_contents>
+                    <has_text text="MDTP&#9;1&#9;0.146721311475"/>
+                    <has_text text="ACRD&#9;1&#9;0.0690453230473"/>
+                </assert_contents>
+            </output>
+            <output name="output_type_ARG" ftype="tabular">
+                <assert_contents>
+                    <has_text text="aminoglycoside&#9;2&#9;0.550769230769"/>
+                    <has_text text="glycopeptide&#9;1&#9;0.312663755459"/>
+                </assert_contents>
+            </output>
+            <output name="output_mapping_potential_ARG" ftype="tabular">
+                <assert_contents>
+                    <has_text text="gi:447120629:ref:WP_001197885.1:|FEATURES|mdtB|multidrug|mdtB"/>
+                    <has_text text="PORIN_OMPC"/>
+                </assert_contents>
+            </output>
+            <output name="output_all_hits" ftype="tabular">
+                <assert_contents>
+                    <has_text text="YP_001966224|FEATURES|catA|phenicol|catA"/>
+                    <has_text text="CP001918.1.gene2931.p01|FEATURES|major_facilitator_superfamily_transporter|multidrug|major_facilitator_superfamily_transporter"/>
+                </assert_contents>
+            </output>
+        </test>        
     </tests>
     <help>
 The DeepARG Short Reads Pipeline is a specialized tool for detecting antibiotic resistance genes (ARGs) directly from **paired-end short read sequencing data**
--- a/macros.xml	Fri Feb 14 11:10:12 2025 +0000
+++ b/macros.xml	Fri Jun 27 12:41:25 2025 +0000
@@ -1,7 +1,7 @@
 <?xml version="1.0"?>
 <xml name="test">
     <token name="@TOOL_VERSION@">1.0.4</token>
-    <token name="@VERSION_SUFFIX@">0</token>
+    <token name="@VERSION_SUFFIX@">1</token>
     <token name="@PROFILE@">22.05</token>
     <xml name="requirements">
         <requirements>