mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-12-23 03:28:17 +00:00
Add test
This commit is contained in:
parent
b1381bb577
commit
3a4fbf36ae
1 changed files with 27 additions and 7 deletions
|
@ -2,14 +2,34 @@
|
||||||
|
|
||||||
nextflow.enable.dsl = 2
|
nextflow.enable.dsl = 2
|
||||||
|
|
||||||
include '../../../../tests/functions/check_process_outputs.nf' params(params)
|
include { FASTQC } from '../main.nf'
|
||||||
include '../main.nf' params(params)
|
|
||||||
|
|
||||||
reads = '../../../../test-datasets/tools/bwa/mem/reads/*_R{1,2}_001.fastq.gz'
|
/*
|
||||||
index = '../../../../test-datasets/tools/bwa/mem/index/H3N2.{amb,ann,bwt,pac,sa}'
|
* Test with single-end data
|
||||||
prefix = 'H3N2'
|
*/
|
||||||
|
workflow test_single_end {
|
||||||
|
|
||||||
|
def input = []
|
||||||
|
input = [ [ id:'test', single_end:true ], // meta map
|
||||||
|
[ file("${baseDir}/input/test_single_end.fastq.gz", checkIfExists: true) ] ]
|
||||||
|
|
||||||
|
FASTQC ( input, [ publish_dir:'test_single_end' ] )
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Test with paired-end data
|
||||||
|
*/
|
||||||
|
workflow test_paired_end {
|
||||||
|
|
||||||
|
def input = []
|
||||||
|
input = [ [ id:'test', single_end:false ], // meta map
|
||||||
|
[ file("${baseDir}/input/test_R1.fastq.gz", checkIfExists: true),
|
||||||
|
file("${baseDir}/input/test_R2.fastq.gz", checkIfExists: true) ] ]
|
||||||
|
|
||||||
|
FASTQC ( input, [ publish_dir:'test_paired_end' ] )
|
||||||
|
}
|
||||||
|
|
||||||
workflow {
|
workflow {
|
||||||
read_input=Channel.fromFilePairs(reads)
|
test_single_end()
|
||||||
bwa_mem(read_input,file(index),prefix)
|
test_paired_end()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue