mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-12-22 11:08:17 +00:00
update test data paths (#373)
* update test data paths * Update test md5sums * gatk test fixes & update variantfiltration main * few extra fixes after review * fix suspected format error * Update software/gatk4/variantfiltration/main.nf * Update software/gatk4/variantfiltration/main.nf * Apply suggestions from code review Co-authored-by: Harshil Patel <drpatelh@users.noreply.github.com>
This commit is contained in:
parent
04c3684db7
commit
889465cb2b
15 changed files with 57 additions and 54 deletions
|
@ -20,11 +20,13 @@ process GATK4_VARIANTFILTRATION {
|
|||
|
||||
input:
|
||||
tuple val(meta), path(vcf)
|
||||
tuple path(fasta), path(fai), path(dict)
|
||||
path fasta
|
||||
path fai
|
||||
path dict
|
||||
|
||||
output:
|
||||
tuple val(meta), path("*filtered.vcf"), emit: vcf
|
||||
path "*.version.txt" , emit: version
|
||||
tuple val(meta), path("*.vcf"), emit: vcf
|
||||
path "*.version.txt" , emit: version
|
||||
|
||||
|
||||
script:
|
||||
|
@ -34,7 +36,7 @@ process GATK4_VARIANTFILTRATION {
|
|||
gatk VariantFiltration \\
|
||||
-R $fasta \\
|
||||
-V $vcf \\
|
||||
-O ${prefix}.filtered.vcf \\
|
||||
-O ${prefix}.vcf \\
|
||||
$options.args
|
||||
|
||||
gatk --version | grep Picard | sed "s/Picard Version: //g" > ${software}.version.txt
|
||||
|
|
|
@ -6,9 +6,9 @@ include { BCFTOOLS_CONSENSUS } from '../../../../software/bcftools/consensus/mai
|
|||
|
||||
workflow test_bcftools_consensus {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test.vcf.gz", checkIfExists: true) ],
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test.vcf.gz.tbi", checkIfExists: true) ],
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/genome/genome.fasta", checkIfExists: true) ]
|
||||
[ file(params.test_data['sarscov2']['illumina']['test_vcf_gz'], checkIfExists: true) ],
|
||||
[ file(params.test_data['sarscov2']['illumina']['test_vcf_gz_tbi'], checkIfExists: true) ],
|
||||
[ file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true) ]
|
||||
]
|
||||
|
||||
BCFTOOLS_CONSENSUS ( input )
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
- name: bcftools consensus
|
||||
command: nextflow run ./tests/software/bcftools/consensus -entry test_bcftools_consensus -c tests/config/nextflow.config
|
||||
- name: bcftools consensus test_bcftools_consensus
|
||||
command: nextflow run tests/software/bcftools/consensus -entry test_bcftools_consensus -c tests/config/nextflow.config
|
||||
tags:
|
||||
- bcftools
|
||||
- bcftools_consensus
|
||||
- bcftools
|
||||
files:
|
||||
- path: output/bcftools/test.fa
|
||||
md5sum: e57d3e4d113f989bc069c5fd61627091
|
||||
|
|
|
@ -7,7 +7,7 @@ include { BCFTOOLS_FILTER } from '../../../../software/bcftools/filter/main.nf'
|
|||
|
||||
workflow test_bcftools_filter {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test.vcf", checkIfExists: true) ]
|
||||
[ file(params.test_data['sarscov2']['illumina']['test_vcf'], checkIfExists: true) ]
|
||||
]
|
||||
|
||||
BCFTOOLS_FILTER ( input )
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
- name: bcftools filter
|
||||
command: nextflow run ./tests/software/bcftools/filter -entry test_bcftools_filter -c tests/config/nextflow.config
|
||||
- name: bcftools filter test_bcftools_filter
|
||||
command: nextflow run tests/software/bcftools/filter -entry test_bcftools_filter -c tests/config/nextflow.config
|
||||
tags:
|
||||
- bcftools
|
||||
- bcftools_filter
|
||||
- bcftools
|
||||
files:
|
||||
- path: output/bcftools/test.vcf.gz
|
||||
md5sum: 9d491cfa84067450342ba8e66c75e5b8
|
||||
|
|
|
@ -6,10 +6,10 @@ include { BCFTOOLS_ISEC } from '../../../../software/bcftools/isec/main.nf' addP
|
|||
|
||||
workflow test_bcftools_isec {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test.vcf.gz", checkIfExists: true),
|
||||
file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test2.vcf.gz", checkIfExists: true)],
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test.vcf.gz.tbi", checkIfExists: true),
|
||||
file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test2.vcf.gz.tbi", checkIfExists: true)]
|
||||
[ file(params.test_data['sarscov2']['illumina']['test_vcf_gz'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test2_vcf_gz'], checkIfExists: true)],
|
||||
[ file(params.test_data['sarscov2']['illumina']['test_vcf_gz_tbi'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test2_vcf_gz_tbi'], checkIfExists: true)]
|
||||
]
|
||||
|
||||
BCFTOOLS_ISEC ( input )
|
||||
|
|
|
@ -1,18 +1,18 @@
|
|||
- name: bcftools isec
|
||||
command: nextflow run ./tests/software/bcftools/isec -entry test_bcftools_isec -c tests/config/nextflow.config
|
||||
- name: bcftools isec test_bcftools_isec
|
||||
command: nextflow run tests/software/bcftools/isec -entry test_bcftools_isec -c tests/config/nextflow.config
|
||||
tags:
|
||||
- bcftools
|
||||
- bcftools_isec
|
||||
files:
|
||||
- path: output/bcftools/test/0000.vcf.gz
|
||||
md5sum: fc178eb342a91dc0d1d568601ad8f8e2
|
||||
- path: output/bcftools/test/0001.vcf.gz.tbi
|
||||
md5sum: 36e11bf96ed0af4a92caa91a68612d64
|
||||
- path: output/bcftools/test/sites.txt
|
||||
md5sum: 1cea3fbde7f6d3c97f3d39036f9690df
|
||||
- path: output/bcftools/test/0000.vcf.gz.tbi
|
||||
md5sum: 36e11bf96ed0af4a92caa91a68612d64
|
||||
- path: output/bcftools/test/0001.vcf.gz
|
||||
md5sum: fc178eb342a91dc0d1d568601ad8f8e2
|
||||
- path: output/bcftools/test/0001.vcf.gz.tbi
|
||||
md5sum: 36e11bf96ed0af4a92caa91a68612d64
|
||||
- path: output/bcftools/test/README.txt
|
||||
md5sum: 10fc33b66522645600d44afbd41fb792
|
||||
- path: output/bcftools/test/sites.txt
|
||||
md5sum: 1cea3fbde7f6d3c97f3d39036f9690df
|
||||
|
|
|
@ -7,10 +7,10 @@ include { BCFTOOLS_MERGE } from '../../../../software/bcftools/merge/main.nf' ad
|
|||
|
||||
workflow test_bcftools_merge {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test2.vcf.gz", checkIfExists: true),
|
||||
file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test3.vcf.gz", checkIfExists: true) ],
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test2.vcf.gz.tbi", checkIfExists: true),
|
||||
file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test3.vcf.gz.tbi", checkIfExists: true) ]
|
||||
[ file(params.test_data['sarscov2']['illumina']['test2_vcf_gz'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test3_vcf_gz'], checkIfExists: true) ],
|
||||
[ file(params.test_data['sarscov2']['illumina']['test2_vcf_gz_tbi'], checkIfExists: true),
|
||||
file(params.test_data['sarscov2']['illumina']['test3_vcf_gz_tbi'], checkIfExists: true) ]
|
||||
]
|
||||
|
||||
BCFTOOLS_MERGE ( input )
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
- name: bcftools merge
|
||||
command: nextflow run ./tests/software/bcftools/merge -entry test_bcftools_merge -c tests/config/nextflow.config
|
||||
- name: bcftools merge test_bcftools_merge
|
||||
command: nextflow run tests/software/bcftools/merge -entry test_bcftools_merge -c tests/config/nextflow.config
|
||||
tags:
|
||||
- bcftools
|
||||
- bcftools_merge
|
||||
- bcftools
|
||||
files:
|
||||
- path: output/bcftools/test.vcf.gz
|
||||
md5sum: 52165fc4149c61547e63800b876c9661
|
||||
|
|
|
@ -7,8 +7,8 @@ include { BCFTOOLS_MPILEUP } from '../../../../software/bcftools/mpileup/main.nf
|
|||
|
||||
workflow test_bcftools_mpileup {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/illumina/bam/test_paired_end.sorted.bam", checkIfExists: true) ]]
|
||||
fasta = [ file("${launchDir}/tests/data/genomics/sarscov2/genome/genome.fasta", checkIfExists: true) ]
|
||||
[ file(params.test_data['sarscov2']['illumina']['test_paired_end_sorted_bam'], checkIfExists: true) ]]
|
||||
fasta = [ file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true) ]
|
||||
|
||||
BCFTOOLS_MPILEUP ( input, fasta )
|
||||
}
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
- name: bcftools mpileup
|
||||
command: nextflow run ./tests/software/bcftools/mpileup -entry test_bcftools_mpileup -c tests/config/nextflow.config
|
||||
- name: bcftools mpileup test_bcftools_mpileup
|
||||
command: nextflow run tests/software/bcftools/mpileup -entry test_bcftools_mpileup -c tests/config/nextflow.config
|
||||
tags:
|
||||
- bcftools
|
||||
- bcftools_mpileup
|
||||
- bcftools
|
||||
files:
|
||||
- path: output/bcftools/test.vcf.gz
|
||||
md5sum: 518f770a9d04004c4493fc2167280653
|
||||
- path: output/bcftools/test.vcf.gz.tbi
|
||||
md5sum: f4be4d707434b3b960fde100b7ec3bf3
|
||||
- path: output/bcftools/test.bcftools_stats.txt
|
||||
md5sum: 2d506e32837a53a01fea0fc90402632a
|
||||
- path: output/bcftools/test.vcf.gz.tbi
|
||||
md5sum: 11d90b5b35e4adf6b44fc53bec93bed3
|
||||
- path: output/bcftools/test.vcf.gz
|
||||
md5sum: 2cf273a9fa3784383799b6b24df2f88c
|
||||
|
|
|
@ -6,7 +6,7 @@ include { BCFTOOLS_STATS } from '../../../../software/bcftools/stats/main.nf' ad
|
|||
|
||||
workflow test_bcftools_stats {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test.vcf", checkIfExists: true) ]
|
||||
[ file(params.test_data['sarscov2']['illumina']['test_vcf'], checkIfExists: true) ]
|
||||
]
|
||||
|
||||
BCFTOOLS_STATS ( input )
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
- name: bcftools stats
|
||||
command: nextflow run ./tests/software/bcftools/stats -entry test_bcftools_stats -c tests/config/nextflow.config
|
||||
- name: bcftools stats test_bcftools_stats
|
||||
command: nextflow run tests/software/bcftools/stats -entry test_bcftools_stats -c tests/config/nextflow.config
|
||||
tags:
|
||||
- bcftools
|
||||
- bcftools_stats
|
||||
|
|
|
@ -2,17 +2,17 @@
|
|||
|
||||
nextflow.enable.dsl = 2
|
||||
|
||||
test_options = ['args': '--filter-name "test_filter" --filter-expression "MQ0 > 0"']
|
||||
test_options = ['args': '--filter-name "test_filter" --filter-expression "MQ0 > 0"', 'suffix': '.filtered']
|
||||
include { GATK4_VARIANTFILTRATION } from '../../../../software/gatk4/variantfiltration/main.nf' addParams( options: test_options )
|
||||
|
||||
workflow test_gatk4_variantfiltration {
|
||||
input = [ [ id:'test' ], // meta map
|
||||
[ file("${launchDir}/tests/data/genomics/sarscov2/illumina/vcf/test.vcf", checkIfExists: true) ]
|
||||
]
|
||||
fasta = [ file("tests/data/genomics/sarscov2/genome/genome.fasta", checkIfExists: true),
|
||||
file("tests/data/genomics/sarscov2/genome/genome.fasta.fai", checkIfExists: true),
|
||||
file("tests/data/genomics/sarscov2/genome/genome.dict", checkIfExists: true)
|
||||
[ file(params.test_data['sarscov2']['illumina']['test_vcf'], checkIfExists: true) ]
|
||||
]
|
||||
fasta = [ file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true) ]
|
||||
fai = [ file(params.test_data['sarscov2']['genome']['genome_fasta_fai'], checkIfExists: true) ]
|
||||
genome_dict = [ file(params.test_data['sarscov2']['genome']['genome_dict'], checkIfExists: true) ]
|
||||
|
||||
GATK4_VARIANTFILTRATION ( input, fasta )
|
||||
|
||||
GATK4_VARIANTFILTRATION ( input, fasta, fai, genome_dict )
|
||||
}
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
- name: Run tests for gatk4/variantfiltration - test_gatk4_variantfiltration
|
||||
command: nextflow run tests/software/gatk4/variantfiltration -entry test_gatk4_variantfiltration
|
||||
-c tests/config/nextflow.config
|
||||
- name: gatk4 variantfiltration test_gatk4_variantfiltration
|
||||
command: nextflow run tests/software/gatk4/variantfiltration -entry test_gatk4_variantfiltration -c tests/config/nextflow.config
|
||||
tags:
|
||||
- gatk4
|
||||
- gatk4_variantfiltration
|
||||
- gatk4
|
||||
files:
|
||||
- path: output/gatk4/test.filtered.vcf
|
||||
contains:
|
||||
- "AC=2;AN=2;DP=1;DP4=0,0,1,0;MQ=60;MQ0F=0;SGB=-0.379885"
|
||||
|
|
Loading…
Reference in a new issue