fix: rename file to input and gz, plus fix tests

This commit is contained in:
MaxUlysse 2021-02-17 00:28:32 +01:00
parent 4f11064ae2
commit 596bb18394
3 changed files with 6 additions and 6 deletions

View file

@ -18,17 +18,17 @@ process TABIX_BGZIP {
}
input:
tuple val(meta), path(file)
tuple val(meta), path(input)
output:
tuple val(meta), path("*.gz"), emit: file
tuple val(meta), path("*.gz"), emit: gz
path "*.version.txt" , emit: version
script:
def software = getSoftwareName(task.process)
def prefix = options.suffix ? "${meta.id}${options.suffix}" : "${meta.id}"
"""
bgzip -c $options.args $file > ${prefix}.${file.getExtension()}.gz
bgzip -c $options.args $input > ${prefix}.${input.getExtension()}.gz
echo \$(bcftools --version 2>&1) | sed 's/^.*bcftools //; s/ .*\$//' > ${software}.version.txt
"""
}

View file

@ -4,7 +4,7 @@ nextflow.enable.dsl = 2
include { TABIX_BGZIP } from '../../../../software/tabix/bgzip/main.nf' addParams( options: [:] )
workflow test_tabix_bgzip_vcf {
workflow test_tabix_bgzip {
def input = []
input = [ [ id:'test' ], // meta map

View file

@ -1,8 +1,8 @@
- name: tabix bgzip
command: nextflow run ./tests/software/tabix/bgzip -entry test_tabix_bgzip_vcf -c tests/config/nextflow.config
command: nextflow run ./tests/software/tabix/bgzip -entry test_tabix_bgzip -c tests/config/nextflow.config
tags:
- tabix
- tabix_bgzip
files:
- path: output/bgzip/test.vcf.gz
- path: output/tabix/test.vcf.gz
md5sum: 40419fb7562475d1c8ec4ab725796de2