diff --git a/tests/pipeline/bismark/samplesheet.nf.test b/tests/pipeline/bismark/samplesheet.nf.test index 6e1534a2..ca5e29fe 100644 --- a/tests/pipeline/bismark/samplesheet.nf.test +++ b/tests/pipeline/bismark/samplesheet.nf.test @@ -5,66 +5,20 @@ nextflow_pipeline { tag "pipeline" - - test("Should ____") { + test("Should handle replicates and works") { when { params { - input = "$baseDir/tests/pipeline/bismark/assets/samplesheet.csv" - outdir = "$outputDir" + aligner = "bismark" + save_reference = true + input = "$baseDir/tests/pipeline/bismark/assets/samplesheet.csv" + outdir = "$outputDir" } } then { assertAll( - { assert workflow.success }, - // TODO Output names should be as expected - { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end_software_versions") }, - { assert snapshot(path("$outputDir/bwameth/alignments/samtools_stats/Ecoli.flagstat"), - path("$outputDir/bwameth/alignments/samtools_stats/Ecoli.stats"), - path("$outputDir/bwameth/alignments/samtools_stats/SRR389222_sub1.flagstat"), - path("$outputDir/bwameth/alignments/samtools_stats/SRR389222_sub1.stats"), - path("$outputDir/bwameth/alignments/samtools_stats/SRR389222_sub2.flagstat"), - path("$outputDir/bwameth/alignments/samtools_stats/SRR389222_sub2.stats"), - path("$outputDir/bwameth/alignments/samtools_stats/SRR389222_sub3.flagstat"), - path("$outputDir/bwameth/alignments/samtools_stats/SRR389222_sub3.stats"), - path("$outputDir/bwameth/deduplicated/Ecoli.markdup.sorted.bam"), - path("$outputDir/bwameth/deduplicated/Ecoli.markdup.sorted.bam.bai"), - path("$outputDir/bwameth/deduplicated/SRR389222_sub1.markdup.sorted.bam"), - path("$outputDir/bwameth/deduplicated/SRR389222_sub1.markdup.sorted.bam.bai"), - path("$outputDir/bwameth/deduplicated/SRR389222_sub2.markdup.sorted.bam"), - path("$outputDir/bwameth/deduplicated/SRR389222_sub2.markdup.sorted.bam.bai"), - path("$outputDir/bwameth/deduplicated/SRR389222_sub3.markdup.sorted.bam"), - path("$outputDir/bwameth/deduplicated/SRR389222_sub3.markdup.sorted.bam.bai"), - path("$outputDir/bwameth/reference_genome/").list(), - path("$outputDir/methyldackel/Ecoli.markdup.sorted_CpG.bedGraph"), - path("$outputDir/methyldackel/SRR389222_sub1.markdup.sorted_CpG.bedGraph"), - path("$outputDir/methyldackel/SRR389222_sub2.markdup.sorted_CpG.bedGraph"), - path("$outputDir/methyldackel/SRR389222_sub3.markdup.sorted_CpG.bedGraph"), - path("$outputDir/methyldackel/mbias/Ecoli.mbias.txt"), - path("$outputDir/methyldackel/mbias/SRR389222_sub1.mbias.txt"), - path("$outputDir/methyldackel/mbias/SRR389222_sub2.mbias.txt"), - path("$outputDir/methyldackel/mbias/SRR389222_sub3.mbias.txt"), - path("$outputDir/qualimap/Ecoli/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub1/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub2/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub3/genome_results.txt")).match("single_end") }, - { assert new File("$outputDir/fastqc/Ecoli_1_fastqc.html").exists() }, - { assert new File("$outputDir/fastqc/Ecoli_2_fastqc.html").exists() }, - { assert new File("$outputDir/fastqc/SRR389222_sub1_fastqc.html").exists() }, - { assert new File("$outputDir/fastqc/SRR389222_sub2_fastqc.html").exists() }, - { assert new File("$outputDir/fastqc/SRR389222_sub3_fastqc.html").exists() }, - { assert new File("$outputDir/multiqc/bwameth/multiqc_report.html").exists() }, - { assert new File("$outputDir/trimgalore/logs/Ecoli_1.fastq.gz_trimming_report.txt").exists() }, - { assert new File("$outputDir/trimgalore/logs/Ecoli_2.fastq.gz_trimming_report.txt").exists() }, - { assert new File("$outputDir/trimgalore/logs/SRR389222_sub1.fastq.gz_trimming_report.txt").exists() }, - { assert new File("$outputDir/trimgalore/logs/SRR389222_sub2.fastq.gz_trimming_report.txt").exists() }, - { assert new File("$outputDir/trimgalore/logs/SRR389222_sub3.fastq.gz_trimming_report.txt").exists() }, - { assert new File("$outputDir/bwameth/deduplicated/picard_metrics/Ecoli.markdup.sorted.MarkDuplicates.metrics.txt").exists() }, - { assert new File("$outputDir/bwameth/deduplicated/picard_metrics/SRR389222_sub1.markdup.sorted.MarkDuplicates.metrics.txt").exists() }, - { assert new File("$outputDir/bwameth/deduplicated/picard_metrics/SRR389222_sub2.markdup.sorted.MarkDuplicates.metrics.txt").exists() }, - { assert new File("$outputDir/bwameth/deduplicated/picard_metrics/SRR389222_sub3.markdup.sorted.MarkDuplicates.metrics.txt").exists() } + { assert workflow.success } ) } } - } diff --git a/tests/pipeline/bismark/samplesheet.nf.test.snap b/tests/pipeline/bismark/samplesheet.nf.test.snap new file mode 100644 index 00000000..916a0ad8 --- /dev/null +++ b/tests/pipeline/bismark/samplesheet.nf.test.snap @@ -0,0 +1,12 @@ +{ + "single_end_software_versions": { + "content": [ + "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, FASTQC={fastqc=0.12.1}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, TRIMGALORE={trimgalore=0.6.7, cutadapt=3.4}, Workflow={nf-core/methylseq=v2.7.0dev}}" + ], + "meta": { + "nf-test": "0.8.4", + "nextflow": "24.04.0" + }, + "timestamp": "2024-05-17T14:37:44.368983" + } +} \ No newline at end of file