2020-08-05 16:27:42 +00:00
|
|
|
#!/usr/bin/env nextflow
|
|
|
|
|
2020-08-07 12:24:24 +00:00
|
|
|
nextflow.enable.dsl = 2
|
|
|
|
|
2020-10-15 09:47:15 +00:00
|
|
|
include { BWA_MEM as BWA_MEM_SE } from '../main.nf' addParams( options: [ publish_dir:'test_single_end' ] )
|
|
|
|
include { BWA_MEM as BWA_MEM_PE } from '../main.nf' addParams( options: [ publish_dir:'test_paired_end' ] )
|
2020-08-07 12:24:24 +00:00
|
|
|
|
|
|
|
/*
|
|
|
|
* Test with single-end data
|
|
|
|
*/
|
|
|
|
workflow test_single_end {
|
|
|
|
|
|
|
|
def input = []
|
|
|
|
input = [ [ id:'test', single_end:true ], // meta map
|
|
|
|
[ file("${baseDir}/input/Ecoli_DNA_R1.fastq.gz", checkIfExists: true) ] ]
|
|
|
|
|
2020-10-15 09:47:15 +00:00
|
|
|
BWA_MEM_SE (
|
2020-08-07 12:24:24 +00:00
|
|
|
input,
|
|
|
|
file("${baseDir}/input/index/NC_010473.fa.{amb,ann,bwt,pac,sa}", checkIfExists: true),
|
2020-10-15 09:47:15 +00:00
|
|
|
file("${baseDir}/input/NC_010473.fa", checkIfExists: true)
|
2020-08-07 12:24:24 +00:00
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Test with paired-end data
|
|
|
|
*/
|
|
|
|
workflow test_paired_end {
|
|
|
|
|
|
|
|
def input = []
|
|
|
|
input = [ [ id:'test', single_end:false ], // meta map
|
|
|
|
[ file("${baseDir}/input/Ecoli_DNA_R1.fastq.gz", checkIfExists: true),
|
|
|
|
file("${baseDir}/input/Ecoli_DNA_R2.fastq.gz", checkIfExists: true) ] ]
|
|
|
|
|
2020-10-15 09:47:15 +00:00
|
|
|
BWA_MEM_PE (
|
2020-08-07 12:24:24 +00:00
|
|
|
input,
|
|
|
|
file("${baseDir}/input/index/NC_010473.fa.{amb,ann,bwt,pac,sa}", checkIfExists: true),
|
2020-10-15 09:47:15 +00:00
|
|
|
file("${baseDir}/input/NC_010473.fa", checkIfExists: true)
|
2020-08-07 12:24:24 +00:00
|
|
|
)
|
|
|
|
}
|
2020-08-05 16:27:42 +00:00
|
|
|
|
|
|
|
workflow {
|
2020-08-07 12:24:24 +00:00
|
|
|
test_single_end()
|
|
|
|
test_paired_end()
|
2020-08-05 16:27:42 +00:00
|
|
|
}
|