mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-12-22 11:08:17 +00:00
test fixes
This commit is contained in:
parent
7e883da904
commit
b4af3f1475
2 changed files with 8 additions and 10 deletions
|
@ -9,7 +9,6 @@ process BAMTOOLS_SPLIT {
|
|||
|
||||
input:
|
||||
tuple val(meta), path(bam)
|
||||
path(bam_list)
|
||||
|
||||
output:
|
||||
tuple val(meta), path("*.bam"), emit: bam
|
||||
|
@ -22,17 +21,13 @@ process BAMTOOLS_SPLIT {
|
|||
def args = task.ext.args ?: ''
|
||||
def prefix = task.ext.prefix ?: "${meta.id}"
|
||||
def input_list = bam.collect{"-in $it"}.join(' ')
|
||||
if (bam_list) {
|
||||
input_list += " -list $bam_list"
|
||||
}
|
||||
if (!args.contains("-stub")) {
|
||||
args += " -stub ${prefix}"
|
||||
}
|
||||
def stub = !args.contains("-stub") ? "-stub ${prefix}" : ""
|
||||
|
||||
"""
|
||||
bamtools merge \\
|
||||
${input_list} \\
|
||||
| bamtools split \\
|
||||
$stub \\
|
||||
$args
|
||||
|
||||
cat <<-END_VERSIONS > versions.yml
|
||||
|
|
|
@ -15,12 +15,15 @@ workflow test_bamtools_split_single_input {
|
|||
BAMTOOLS_SPLIT_SINGLE ( input )
|
||||
}
|
||||
|
||||
workflow test_bamtools_split_multiple_input {
|
||||
workflow test_bamtools_split_multiple {
|
||||
|
||||
input = [
|
||||
[ id:'test', single_end:false ], // meta map
|
||||
[file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true), file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_sorted_bam'], checkIfExists: true)]
|
||||
[
|
||||
[file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true),
|
||||
file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true)]
|
||||
|
||||
]
|
||||
|
||||
BAMTOOLS_SPLIT_MULTIPLE ( input )
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue