From 46e5752b82fb9d0f8d472b3d87efa7419f658279 Mon Sep 17 00:00:00 2001 From: Ramprasad Neethiraj <20065894+ramprasadn@users.noreply.github.com> Date: Tue, 3 May 2022 14:32:45 +0200 Subject: [PATCH] update tests --- tests/modules/cnvpytor/callcnvs/test.yml | 4 +- tests/modules/cnvpytor/view/main.nf | 43 +++++++++++++++++++++ tests/modules/cnvpytor/view/nextflow.config | 7 ++++ tests/modules/cnvpytor/view/test.yml | 26 +++++++++++++ 4 files changed, 78 insertions(+), 2 deletions(-) create mode 100644 tests/modules/cnvpytor/view/main.nf create mode 100644 tests/modules/cnvpytor/view/nextflow.config create mode 100644 tests/modules/cnvpytor/view/test.yml diff --git a/tests/modules/cnvpytor/callcnvs/test.yml b/tests/modules/cnvpytor/callcnvs/test.yml index e284ab53..fd07db4c 100644 --- a/tests/modules/cnvpytor/callcnvs/test.yml +++ b/tests/modules/cnvpytor/callcnvs/test.yml @@ -4,7 +4,7 @@ - cnvpytor - cnvpytor/callcnvs files: - - path: output/cnvpytor/test.tsv + - path: output/cnvpytor/test.pytor - path: output/cnvpytor/versions.yml - name: cnvpytor callcnvs test_cnvpytor_callcnvs stub @@ -13,5 +13,5 @@ - cnvpytor - cnvpytor/callcnvs files: - - path: output/cnvpytor/test.tsv + - path: output/cnvpytor/test.pytor - path: output/cnvpytor/versions.yml diff --git a/tests/modules/cnvpytor/view/main.nf b/tests/modules/cnvpytor/view/main.nf new file mode 100644 index 00000000..30177c44 --- /dev/null +++ b/tests/modules/cnvpytor/view/main.nf @@ -0,0 +1,43 @@ +#!/usr/bin/env nextflow + +nextflow.enable.dsl = 2 + +include { CNVPYTOR_VIEW } from '../../../../modules/cnvpytor/view/main.nf' + +workflow test_cnvpytor_view { + + input = [ + [ id:'test'], // meta map + file(params.test_data['homo_sapiens']['illumina']['test_pytor'], checkIfExists: true) + ] + + bin_sizes = "10000 100000" + + CNVPYTOR_VIEW ( input, bin_sizes, [] ) +} + +workflow test_cnvpytor_view_tsvout { + + input = [ + [ id:'test'], // meta map + file(params.test_data['homo_sapiens']['illumina']['test_pytor'], checkIfExists: true) + ] + + bin_sizes = "10000" + output_suffix = "tsv" + + CNVPYTOR_VIEW ( input, bin_sizes, output_suffix ) +} + +workflow test_cnvpytor_view_stub { + + input = [ + [ id:'test'], // meta map + file(params.test_data['homo_sapiens']['illumina']['test_pytor'], checkIfExists: true) + ] + + bin_sizes = "10000" + output_suffix = "tsv" + + CNVPYTOR_VIEW ( input, bin_sizes, output_suffix ) +} diff --git a/tests/modules/cnvpytor/view/nextflow.config b/tests/modules/cnvpytor/view/nextflow.config new file mode 100644 index 00000000..6d2cc1fb --- /dev/null +++ b/tests/modules/cnvpytor/view/nextflow.config @@ -0,0 +1,7 @@ +process { + + publishDir = { "${params.outdir}/${task.process.tokenize(':')[-1].tokenize('_')[0].toLowerCase()}" } + withName: CNVPYTOR_VIEW { + ext.args = '10000 100000' + } +} diff --git a/tests/modules/cnvpytor/view/test.yml b/tests/modules/cnvpytor/view/test.yml new file mode 100644 index 00000000..38f75003 --- /dev/null +++ b/tests/modules/cnvpytor/view/test.yml @@ -0,0 +1,26 @@ +- name: cnvpytor view test_cnvpytor_view + command: nextflow run tests/modules/cnvpytor/view -entry test_cnvpytor_view -c tests/config/nextflow.config + tags: + - cnvpytor + - cnvpytor/view + files: + - path: output/cnvpytor/test_10000.vcf + - path: output/cnvpytor/versions.yml + +- name: cnvpytor view test_cnvpytor_view tsv + command: nextflow run tests/modules/cnvpytor/view -entry test_cnvpytor_view_tsvout -c tests/config/nextflow.config + tags: + - cnvpytor + - cnvpytor/view + files: + - path: output/cnvpytor/test.tsv + - path: output/cnvpytor/versions.yml + +- name: cnvpytor view test_cnvpytor_view stub + command: nextflow run tests/modules/cnvpytor/view -entry test_cnvpytor_view_stub -c tests/config/nextflow.config -stub-run + tags: + - cnvpytor + - cnvpytor/view + files: + - path: output/cnvpytor/test.vcf + - path: output/cnvpytor/versions.yml