diff --git a/modules/nf-core/gatk4/fastqtosam/tests/main.nf.test b/modules/nf-core/gatk4/fastqtosam/tests/main.nf.test new file mode 100644 index 00000000000..2e3688a779d --- /dev/null +++ b/modules/nf-core/gatk4/fastqtosam/tests/main.nf.test @@ -0,0 +1,64 @@ + +nextflow_process { + + name "Test Process GATK4_FASTQTOSAM" + script "../main.nf" + process "GATK4_FASTQTOSAM" + + tag "modules" + tag "modules_nfcore" + tag "gatk4" + tag "gatk4/fastqtosam" + + test("test-gatk4-fastqtosam-single-end") { + + when { + process { + """ + input[0] = [ [ id:'test', single_end:true ], // meta map + file(params.modules_testdata_base_path + 'genomics/sarscov2/illumina/fastq/test_1.fastq.gz', checkIfExists: true) + ] + + """ + } + } + + then { + assertAll( + { assert process.success }, + { assert snapshot( + bam(process.out.bam[0][1]).getReadsMD5(), + process.out.versions + ).match() + } + ) + } + } + + test("test-gatk4-fastqtosam-paired-end") { + + when { + process { + """ + input[0] = [ [ id:'test', single_end:false ], // meta map + file(params.modules_testdata_base_path + 'genomics/sarscov2/illumina/fastq/test_1.fastq.gz', checkIfExists: true), + file(params.modules_testdata_base_path + 'genomics/sarscov2/illumina/fastq/test_2.fastq.gz', checkIfExists: true) + ] + + """ + } + } + + then { + assertAll( + { assert process.success }, + { assert snapshot( + bam(process.out.bam[0][1]).getReadsMD5(), + process.out.versions + ).match() + } + ) + } + } + +} diff --git a/modules/nf-core/gatk4/fastqtosam/tests/main.nf.test.snap b/modules/nf-core/gatk4/fastqtosam/tests/main.nf.test.snap new file mode 100644 index 00000000000..554480a24b7 --- /dev/null +++ b/modules/nf-core/gatk4/fastqtosam/tests/main.nf.test.snap @@ -0,0 +1,28 @@ +{ + "test-gatk4-fastqtosam-single-end": { + "content": [ + "e6a4aa204d980e177a0458596f0a70ac", + [ + "versions.yml:md5,ac3f2cf1b686e56d72f1dd4a5977f7ab" + ] + ], + "meta": { + "nf-test": "0.8.4", + "nextflow": "24.04.4" + }, + "timestamp": "2024-08-26T12:29:12.362942" + }, + "test-gatk4-fastqtosam-paired-end": { + "content": [ + "e6a4aa204d980e177a0458596f0a70ac", + [ + "versions.yml:md5,ac3f2cf1b686e56d72f1dd4a5977f7ab" + ] + ], + "meta": { + "nf-test": "0.8.4", + "nextflow": "24.04.4" + }, + "timestamp": "2024-08-26T12:29:22.385798" + } +} \ No newline at end of file diff --git a/tests/config/pytest_modules.yml b/tests/config/pytest_modules.yml index 4aea9c2af1e..8993f36704b 100644 --- a/tests/config/pytest_modules.yml +++ b/tests/config/pytest_modules.yml @@ -464,9 +464,6 @@ gatk4/createsomaticpanelofnormals: gatk4/determinegermlinecontigploidy: - modules/nf-core/gatk4/determinegermlinecontigploidy/** - tests/modules/nf-core/gatk4/determinegermlinecontigploidy/** -gatk4/fastqtosam: - - modules/nf-core/gatk4/fastqtosam/** - - tests/modules/nf-core/gatk4/fastqtosam/** gatk4/filterintervals: - modules/nf-core/gatk4/filterintervals/** - tests/modules/nf-core/gatk4/filterintervals/** diff --git a/tests/modules/nf-core/gatk4/fastqtosam/main.nf b/tests/modules/nf-core/gatk4/fastqtosam/main.nf deleted file mode 100644 index 0a3aef644d4..00000000000 --- a/tests/modules/nf-core/gatk4/fastqtosam/main.nf +++ /dev/null @@ -1,22 +0,0 @@ -#!/usr/bin/env nextflow - -nextflow.enable.dsl = 2 - -include { GATK4_FASTQTOSAM } from '../../../../../modules/nf-core/gatk4/fastqtosam/main.nf' - -workflow test_gatk4_fastqtosam_single_end { - input = [ [ id:'test', single_end:true ], // meta map - file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true) - ] - - GATK4_FASTQTOSAM ( input ) -} - -workflow test_gatk4_fastqtosam_paired_end { - input = [ [ id:'test', single_end:false ], // meta map - file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true), - file(params.test_data['sarscov2']['illumina']['test_2_fastq_gz'], checkIfExists: true) - ] - - GATK4_FASTQTOSAM ( input ) -} diff --git a/tests/modules/nf-core/gatk4/fastqtosam/nextflow.config b/tests/modules/nf-core/gatk4/fastqtosam/nextflow.config deleted file mode 100644 index 8730f1c4b93..00000000000 --- a/tests/modules/nf-core/gatk4/fastqtosam/nextflow.config +++ /dev/null @@ -1,5 +0,0 @@ -process { - - publishDir = { "${params.outdir}/${task.process.tokenize(':')[-1].tokenize('_')[0].toLowerCase()}" } - -} diff --git a/tests/modules/nf-core/gatk4/fastqtosam/test.yml b/tests/modules/nf-core/gatk4/fastqtosam/test.yml deleted file mode 100644 index 482284d5956..00000000000 --- a/tests/modules/nf-core/gatk4/fastqtosam/test.yml +++ /dev/null @@ -1,16 +0,0 @@ -- name: gatk4 fastqtosam test_gatk4_fastqtosam_single_end - command: nextflow run ./tests/modules/nf-core/gatk4/fastqtosam -entry test_gatk4_fastqtosam_single_end -c ./tests/config/nextflow.config -c ./tests/modules/nf-core/gatk4/fastqtosam/nextflow.config - tags: - - gatk4 - - gatk4/fastqtosam - files: - - path: output/gatk4/test.bam - -- name: gatk4 fastqtosam test_gatk4_fastqtosam_paired_end - command: nextflow run ./tests/modules/nf-core/gatk4/fastqtosam -entry test_gatk4_fastqtosam_paired_end -c ./tests/config/nextflow.config -c ./tests/modules/nf-core/gatk4/fastqtosam/nextflow.config - tags: - - gatk4 - - gatk4/fastqtosam - files: - - path: output/gatk4/test.bam - - path: output/gatk4/versions.yml