diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index dcd9ff10..699e5287 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,42 +21,45 @@ concurrency: cancel-in-progress: true jobs: + define_nxf_versions: + name: Choose nextflow versions to test against depending on target branch + runs-on: ubuntu-latest + outputs: + matrix: ${{ steps.nxf_versions.outputs.matrix }} + steps: + - id: nxf_versions + run: | + if [[ "${{ github.event_name }}" == "pull_request" && "${{ github.base_ref }}" == "dev" && "${{ matrix.NXF_VER }}" != "latest-everything" ]]; then + echo matrix='["latest-everything"]' | tee -a $GITHUB_OUTPUT + else + echo matrix='["latest-everything", "23.04.0"]' | tee -a $GITHUB_OUTPUT + fi + test: name: Run pipeline with test data + needs: define_nxf_versions runs-on: ubuntu-latest strategy: fail-fast: false matrix: - NXF_VER: - - "23.04.0" - - "latest-everything" - aligner: + NXF_VER: ${{ fromJson(needs.define_nxf_versions.outputs.matrix) }} + test_tags: - "bismark" - "bismark_hisat" - "bwameth" profile: - "docker" - steps: - # Skip if it's a pull_request to dev and NXF_VER is '22.10.1' - - name: Skip condition - id: condition - run: | - if [[ "${{ github.event_name }}" == "pull_request" && "${{ github.base_ref }}" == "dev" && "${{ matrix.NXF_VER }}" != "latest-everything" ]]; then - echo "skip=true" >> $GITHUB_OUTPUT - fi + steps: - name: Check out pipeline code - if: steps.condition.outputs.skip != 'true' uses: actions/checkout@v3 - name: Hash Github Workspace - if: steps.condition.outputs.skip != 'true' id: hash_workspace run: | echo "digest=$(echo methylseq2_${{ github.workspace }} | md5sum | cut -c 1-25)" >> $GITHUB_OUTPUT - name: Cache test data - if: steps.condition.outputs.skip != 'true' id: cache-testdata uses: actions/cache@v3 with: @@ -64,7 +67,6 @@ jobs: key: ${{ steps.hash_workspace.outputs.digest }} - name: Check out test data - if: steps.cache-testdata.outputs.cache-hit != 'true' && steps.condition.outputs.skip != 'true' uses: actions/checkout@v3 with: repository: nf-core/test-datasets @@ -72,7 +74,6 @@ jobs: path: test-datasets/ - name: Replace remote paths in samplesheets - if: steps.condition.outputs.skip != 'true' run: | for f in ./test-datasets/samplesheet/*csv; do sed -i 's=https://github.com/nf-core/test-datasets/raw/methylseq/=./test-datasets/=g' $f @@ -83,25 +84,27 @@ jobs: done; - name: Install Nextflow - if: steps.condition.outputs.skip != 'true' uses: nf-core/setup-nextflow@v1 with: version: "${{ matrix.NXF_VER }}" - name: Install nf-test - if: steps.condition.outputs.skip != 'true' run: | wget -qO- https://code.askimed.com/install/nf-test | bash -s $NFTEST_VER sudo mv nf-test /usr/local/bin/ - name: Run nf-test - if: steps.condition.outputs.skip != 'true' run: | - nf-test test tests/pipeline/${{ matrix.aligner }}/ --profile "test,${{ matrix.profile }}" --tap=test.tap + nf-test test --tag ${{ matrix.test_tags }} --profile "test,${{ matrix.profile }}" --junitxml=test.xml - # If the test fails, output the software_versions.yml using the 'batcat' utility - name: Output log on failure if: failure() run: | sudo apt install bat > /dev/null batcat --decorations=always --color=always ${{ github.workspace }}/.nf-test/tests/*/output/pipeline_info/software_versions.yml + + - name: Publish Test Report + uses: mikepenz/action-junit-report@v3 + if: always() # always run even if the previous step fails + with: + report_paths: test.xml diff --git a/CHANGELOG.md b/CHANGELOG.md index e0078f30..f591a8fe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ - Updated template to nf-core/tools v2.9 - Updated nf-core modules for FastQC, samtools sort, samtools flagstat - Removes problematic `-m` memory assignment for samtools sort [#81](https://github.com/nf-core/methylseq/issues/81) +- Use `fromSamplesheet` from nf-validation [#341](https://github.com/nf-core/methylseq/pull/341) ### Bug fixes & refactoring diff --git a/assets/schema_input.json b/assets/schema_input.json index e50fcf2e..9e51e2e9 100644 --- a/assets/schema_input.json +++ b/assets/schema_input.json @@ -10,15 +10,21 @@ "sample": { "type": "string", "pattern": "^\\S+$", - "errorMessage": "Sample name must be provided and cannot contain spaces" + "errorMessage": "Sample name must be provided and cannot contain spaces", + "meta": ["id"] }, "fastq_1": { "type": "string", + "format": "file-path", + "exists": true, "pattern": "^\\S+\\.f(ast)?q\\.gz$", "errorMessage": "FastQ file for reads 1 must be provided, cannot contain spaces and must have extension '.fq.gz' or '.fastq.gz'" }, "fastq_2": { "errorMessage": "FastQ file for reads 2 cannot contain spaces and must have extension '.fq.gz' or '.fastq.gz'", + "type": "string", + "format": "file-path", + "exists": true, "anyOf": [ { "type": "string", diff --git a/modules/local/samplesheet_check.nf b/modules/local/samplesheet_check.nf deleted file mode 100644 index 3043b83b..00000000 --- a/modules/local/samplesheet_check.nf +++ /dev/null @@ -1,32 +0,0 @@ -process SAMPLESHEET_CHECK { - tag "$samplesheet" - label 'process_single' - - conda "conda-forge::python=3.8.3" - container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/python:3.8.3' : - 'biocontainers/python:3.8.3' }" - - input: - path samplesheet - - output: - path '*.csv' , emit: csv - path "versions.yml", emit: versions - - when: - task.ext.when == null || task.ext.when - - script: // This script is bundled with the pipeline, in nf-core/methylseq/bin/ - // def reference = params.fasta ? "--genome ${params.fasta}" : "" - """ - check_samplesheet.py \\ - $samplesheet \\ - samplesheet.valid.csv - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - python: \$(python --version | sed 's/Python //g') - END_VERSIONS - """ -} diff --git a/subworkflows/local/input_check.nf b/subworkflows/local/input_check.nf deleted file mode 100644 index 0aecf87f..00000000 --- a/subworkflows/local/input_check.nf +++ /dev/null @@ -1,44 +0,0 @@ -// -// Check input samplesheet and get read channels -// - -include { SAMPLESHEET_CHECK } from '../../modules/local/samplesheet_check' - -workflow INPUT_CHECK { - take: - samplesheet // file: /path/to/samplesheet.csv - - main: - SAMPLESHEET_CHECK ( samplesheet ) - .csv - .splitCsv ( header:true, sep:',' ) - .map { create_fastq_channel(it) } - .set { reads } - - emit: - reads // channel: [ val(meta), [ reads ] ] - versions = SAMPLESHEET_CHECK.out.versions // channel: [ versions.yml ] -} - -// Function to get list of [ meta, [ fastq_1, fastq_2 ] ] -def create_fastq_channel(LinkedHashMap row) { - // create meta map - def meta = [:] - meta.id = row.sample - meta.single_end = row.single_end.toBoolean() - - // add path(s) of the fastq file(s) to the meta map - def fastq_meta = [] - if (!file(row.fastq_1).exists()) { - exit 1, "ERROR: Please check input samplesheet -> Read 1 FastQ file does not exist!\n${row.fastq_1}" - } - if (meta.single_end) { - fastq_meta = [ meta, [ file(row.fastq_1) ] ] - } else { - if (!file(row.fastq_2).exists()) { - exit 1, "ERROR: Please check input samplesheet -> Read 2 FastQ file does not exist!\n${row.fastq_2}" - } - fastq_meta = [ meta, [ file(row.fastq_1), file(row.fastq_2) ] ] - } - return fastq_meta -} diff --git a/tests/pipeline/bismark/main.nf.test b/tests/pipeline/bismark/main.nf.test index 2bd75c9c..72af7acd 100644 --- a/tests/pipeline/bismark/main.nf.test +++ b/tests/pipeline/bismark/main.nf.test @@ -29,14 +29,34 @@ nextflow_pipeline { assertAll( { assert workflow.success }, - { assert snapshot(path("$outputDir/bismark/methylation_calls/splitting_report/Ecoli_10K_methylated_1_val_1_bismark_bt2_pe.deduplicated_splitting_report.txt"), - path("$outputDir/bismark/methylation_calls/splitting_report/SRR389222_sub1_trimmed_bismark_bt2.deduplicated_splitting_report.txt"), - path("$outputDir/bismark/methylation_calls/splitting_report/SRR389222_sub2_trimmed_bismark_bt2.deduplicated_splitting_report.txt"), - path("$outputDir/qualimap/Ecoli_10K_methylated/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub1/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub2/genome_results.txt")).match("single_end") }, + { assert snapshot(path("$outputDir/bismark/deduplicated/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bam"), + path("$outputDir/bismark/deduplicated/SRR389222_trimmed_bismark_bt2.deduplicated.bam"), + path("$outputDir/bismark/methylation_calls/bedGraph/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bedGraph.gz"), + path("$outputDir/bismark/methylation_calls/bedGraph/SRR389222_trimmed_bismark_bt2.deduplicated.bedGraph.gz"), + path("$outputDir/bismark/methylation_calls/mbias/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.M-bias.txt"), + path("$outputDir/bismark/methylation_calls/mbias/SRR389222_trimmed_bismark_bt2.deduplicated.M-bias.txt"), + path("$outputDir/bismark/methylation_calls/methylation_coverage/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bismark.cov.gz"), + path("$outputDir/bismark/methylation_calls/methylation_coverage/SRR389222_trimmed_bismark_bt2.deduplicated.bismark.cov.gz"), + path("$outputDir/bismark/methylation_calls/methylation_calls/").list(), + path("$outputDir/bismark/methylation_calls/splitting_report/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated_splitting_report.txt"), + path("$outputDir/bismark/methylation_calls/splitting_report/SRR389222_trimmed_bismark_bt2.deduplicated_splitting_report.txt"), + path("$outputDir/bismark/reference_genome/BismarkIndex/").list(), + path("$outputDir/qualimap/Ecoli_10K/genome_results.txt"), + path("$outputDir/qualimap/SRR389222/genome_results.txt")).match("single_end") }, { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end_software_versions") }, - { assert new File("$outputDir/bismark/summary/bismark_summary_report.txt").exists() } + { assert new File("$outputDir/bismark/alignments/logs/Ecoli_10K_1_val_1_bismark_bt2_PE_report.txt").exists() }, + { assert new File("$outputDir/bismark/alignments/logs/SRR389222_trimmed_bismark_bt2_SE_report.txt").exists() }, + { assert new File("$outputDir/bismark/reports/Ecoli_10K_1_val_1_bismark_bt2_PE_report.html").exists() }, + { assert new File("$outputDir/bismark/reports/SRR389222_trimmed_bismark_bt2_SE_report.html").exists() }, + { assert new File("$outputDir/bismark/summary/bismark_summary_report.html").exists() }, + { assert new File("$outputDir/bismark/summary/bismark_summary_report.txt").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_1_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_2_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/SRR389222_fastqc.html").exists() }, + { assert new File("$outputDir/multiqc/bismark/multiqc_report.html").exists() }, + { assert new File("$outputDir/trimgalore/logs/Ecoli_10K_1.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/trimgalore/logs/Ecoli_10K_2.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/trimgalore/logs/SRR389222.fastq.gz_trimming_report.txt").exists() } ) } } @@ -71,14 +91,31 @@ nextflow_pipeline { then { assertAll( { assert workflow.success }, - { assert snapshot(path("$outputDir/bismark/methylation_calls/splitting_report/Ecoli_10K_methylated_R1_bismark_bt2_pe_splitting_report.txt"), - path("$outputDir/bismark/methylation_calls/splitting_report/SRR389222_sub1_bismark_bt2_splitting_report.txt"), - path("$outputDir/bismark/methylation_calls/splitting_report/SRR389222_sub2.merged_bismark_bt2_splitting_report.txt"), - path("$outputDir/qualimap/Ecoli_10K_methylated/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub1/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub2/genome_results.txt")).match("single_end_rrbs") }, + { assert snapshot(path("$outputDir/bismark/alignments/Ecoli_10K_methylated_R1_bismark_bt2_pe.bam"), + path("$outputDir/bismark/alignments/SRR389222.merged_bismark_bt2.bam"), + path("$outputDir/bismark/methylation_calls/bedGraph/Ecoli_10K_methylated_R1_bismark_bt2_pe.bedGraph.gz"), + path("$outputDir/bismark/methylation_calls/bedGraph/SRR389222.merged_bismark_bt2.bedGraph.gz"), + path("$outputDir/bismark/methylation_calls/mbias/Ecoli_10K_methylated_R1_bismark_bt2_pe.M-bias.txt"), + path("$outputDir/bismark/methylation_calls/mbias/SRR389222.merged_bismark_bt2.M-bias.txt"), + path("$outputDir/bismark/methylation_calls/methylation_coverage/Ecoli_10K_methylated_R1_bismark_bt2_pe.bismark.cov.gz"), + path("$outputDir/bismark/methylation_calls/methylation_coverage/SRR389222.merged_bismark_bt2.bismark.cov.gz"), + path("$outputDir/bismark/methylation_calls/methylation_calls/").list(), + path("$outputDir/bismark/methylation_calls/splitting_report/Ecoli_10K_methylated_R1_bismark_bt2_pe_splitting_report.txt"), + path("$outputDir/bismark/methylation_calls/splitting_report/SRR389222.merged_bismark_bt2_splitting_report.txt"), + path("$outputDir/bismark/reference_genome/BismarkIndex/").list(), + path("$outputDir/qualimap/Ecoli_10K/genome_results.txt"), + path("$outputDir/qualimap/SRR389222/genome_results.txt")).match("single_end_rrbs") }, { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end_rrbs_software_versions") }, - { assert new File("$outputDir/bismark/summary/bismark_summary_report.txt").exists() } + { assert new File("$outputDir/bismark/alignments/logs/Ecoli_10K_methylated_R1_bismark_bt2_PE_report.txt").exists() }, + { assert new File("$outputDir/bismark/alignments/logs/SRR389222.merged_bismark_bt2_SE_report.txt").exists() }, + { assert new File("$outputDir/bismark/reports/Ecoli_10K_methylated_R1_bismark_bt2_PE_report.html").exists() }, + { assert new File("$outputDir/bismark/reports/SRR389222.merged_bismark_bt2_SE_report.html").exists() }, + { assert new File("$outputDir/bismark/summary/bismark_summary_report.html").exists() }, + { assert new File("$outputDir/bismark/summary/bismark_summary_report.txt").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_1_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_2_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/SRR389222_fastqc.html").exists() }, + { assert new File("$outputDir/multiqc/bismark/multiqc_report.html").exists() } ) } } @@ -113,19 +150,43 @@ nextflow_pipeline { then { assertAll( { assert workflow.success }, - { assert snapshot(path("$outputDir/bismark/methylation_calls/splitting_report/Ecoli_10K_methylated_1_val_1_bismark_bt2_pe.deduplicated_splitting_report.txt"), - path("$outputDir/bismark/methylation_calls/splitting_report/SRR389222_sub1_trimmed_bismark_bt2.deduplicated_splitting_report.txt"), - path("$outputDir/bismark/methylation_calls/splitting_report/SRR389222_sub2_trimmed_bismark_bt2.deduplicated_splitting_report.txt"), - path("$outputDir/qualimap/Ecoli_10K_methylated/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub1/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub2/genome_results.txt")).match("single_end_nomeseq") }, - { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end_nomeseq_software_versions") }, - { assert new File("$outputDir/bismark/summary/bismark_summary_report.txt").exists() } + { assert snapshot(path("$outputDir/bismark/coverage2cytosine/coverage/Ecoli_10K.NOMe.CpG.cov.gz"), + path("$outputDir/bismark/coverage2cytosine/coverage/Ecoli_10K.NOMe.GpC.cov.gz"), + path("$outputDir/bismark/coverage2cytosine/coverage/SRR389222.NOMe.CpG.cov.gz"), + path("$outputDir/bismark/coverage2cytosine/coverage/SRR389222.NOMe.GpC.cov.gz"), + path("$outputDir/bismark/deduplicated/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bam"), + path("$outputDir/bismark/deduplicated/SRR389222_trimmed_bismark_bt2.deduplicated.bam"), + path("$outputDir/bismark/methylation_calls/bedGraph/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bedGraph.gz"), + path("$outputDir/bismark/methylation_calls/bedGraph/SRR389222_trimmed_bismark_bt2.deduplicated.bedGraph.gz"), + path("$outputDir/bismark/methylation_calls/mbias/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.M-bias.txt"), + path("$outputDir/bismark/methylation_calls/mbias/SRR389222_trimmed_bismark_bt2.deduplicated.M-bias.txt"), + path("$outputDir/bismark/methylation_calls/methylation_coverage/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bismark.cov.gz"), + path("$outputDir/bismark/methylation_calls/methylation_coverage/SRR389222_trimmed_bismark_bt2.deduplicated.bismark.cov.gz"), + path("$outputDir/bismark/methylation_calls/methylation_calls/").list(), + path("$outputDir/bismark/methylation_calls/splitting_report/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated_splitting_report.txt"), + path("$outputDir/bismark/methylation_calls/splitting_report/SRR389222_trimmed_bismark_bt2.deduplicated_splitting_report.txt"), + path("$outputDir/cat/SRR389222.merged.fastq.gz"), + path("$outputDir/qualimap/Ecoli_10K/genome_results.txt"), + path("$outputDir/qualimap/SRR389222/genome_results.txt")).match("single_end_nomeseq") }, + { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end__nomeseq_software_versions") }, + { assert new File("$outputDir/bismark/alignments/logs/Ecoli_10K_1_val_1_bismark_bt2_PE_report.txt").exists() }, + { assert new File("$outputDir/bismark/alignments/logs/SRR389222_trimmed_bismark_bt2_SE_report.txt").exists() }, + { assert new File("$outputDir/bismark/reports/Ecoli_10K_1_val_1_bismark_bt2_PE_report.html").exists() }, + { assert new File("$outputDir/bismark/reports/SRR389222_trimmed_bismark_bt2_SE_report.html").exists() }, + { assert new File("$outputDir/bismark/summary/bismark_summary_report.html").exists() }, + { assert new File("$outputDir/bismark/summary/bismark_summary_report.txt").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_1_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_2_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/SRR389222_fastqc.html").exists() }, + { assert new File("$outputDir/multiqc/bismark/multiqc_report.html").exists() }, + { assert new File("$outputDir/trimgalore/logs/Ecoli_10K_1.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/trimgalore/logs/Ecoli_10K_2.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/trimgalore/logs/SRR389222.fastq.gz_trimming_report.txt").exists() } ) } } - test("Bismark Clipping Params") { + test("Bismark Clip R1 - 2") { when { params { aligner = "bismark" @@ -138,10 +199,35 @@ nextflow_pipeline { then { assertAll( { assert workflow.success }, - { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("clipping_params_software_versions") }, - { assert new File("$outputDir/bismark/summary/bismark_summary_report.txt").exists() } + { assert snapshot(path("$outputDir/bismark/deduplicated/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bam"), + path("$outputDir/bismark/deduplicated/SRR389222_trimmed_bismark_bt2.deduplicated.bam"), + path("$outputDir/bismark/methylation_calls/bedGraph/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bedGraph.gz"), + path("$outputDir/bismark/methylation_calls/bedGraph/SRR389222_trimmed_bismark_bt2.deduplicated.bedGraph.gz"), + path("$outputDir/bismark/methylation_calls/mbias/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.M-bias.txt"), + path("$outputDir/bismark/methylation_calls/mbias/SRR389222_trimmed_bismark_bt2.deduplicated.M-bias.txt"), + path("$outputDir/bismark/methylation_calls/methylation_coverage/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bismark.cov.gz"), + path("$outputDir/bismark/methylation_calls/methylation_coverage/SRR389222_trimmed_bismark_bt2.deduplicated.bismark.cov.gz"), + path("$outputDir/bismark/methylation_calls/methylation_calls/").list(), + path("$outputDir/bismark/methylation_calls/splitting_report/Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated_splitting_report.txt"), + path("$outputDir/bismark/methylation_calls/splitting_report/SRR389222_trimmed_bismark_bt2.deduplicated_splitting_report.txt"), + path("$outputDir/cat/SRR389222.merged.fastq.gz"), + path("$outputDir/qualimap/Ecoli_10K/genome_results.txt"), + path("$outputDir/qualimap/SRR389222/genome_results.txt")).match("clip_r1") }, + { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("clip_r1_software_versions") }, + { assert new File("$outputDir/bismark/alignments/logs/Ecoli_10K_1_val_1_bismark_bt2_PE_report.txt").exists() }, + { assert new File("$outputDir/bismark/alignments/logs/SRR389222_trimmed_bismark_bt2_SE_report.txt").exists() }, + { assert new File("$outputDir/bismark/reports/Ecoli_10K_1_val_1_bismark_bt2_PE_report.html").exists() }, + { assert new File("$outputDir/bismark/reports/SRR389222_trimmed_bismark_bt2_SE_report.html").exists() }, + { assert new File("$outputDir/bismark/summary/bismark_summary_report.html").exists() }, + { assert new File("$outputDir/bismark/summary/bismark_summary_report.txt").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_1_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_2_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/SRR389222_fastqc.html").exists() }, + { assert new File("$outputDir/multiqc/bismark/multiqc_report.html").exists() }, + { assert new File("$outputDir/trimgalore/logs/Ecoli_10K_1.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/trimgalore/logs/Ecoli_10K_2.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/trimgalore/logs/SRR389222.fastq.gz_trimming_report.txt").exists() } ) } } - } diff --git a/tests/pipeline/bismark/main.nf.test.snap b/tests/pipeline/bismark/main.nf.test.snap index 64d7422f..a746a936 100644 --- a/tests/pipeline/bismark/main.nf.test.snap +++ b/tests/pipeline/bismark/main.nf.test.snap @@ -1,59 +1,208 @@ { - "clipping_params_software_versions": { - "content": [ - "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, SAMPLESHEET_CHECK={python=3.8.3}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" - ], - "timestamp": "2023-06-01T02:27:54+0000" - }, "single_end_software_versions": { "content": [ - "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, SAMPLESHEET_CHECK={python=3.8.3}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" + "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" ], - "timestamp": "2023-06-01T02:27:54+0000" + "timestamp": "2023-08-28T08:46:48+0000" }, "single_end_nomeseq_software_versions": { "content": [ - "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, SAMPLESHEET_CHECK={python=3.8.3}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" + "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" ], - "timestamp": "2023-06-01T02:27:54+0000" + "timestamp": "2023-08-28T08:46:48+0000" }, "single_end_nomeseq": { "content": [ - "Ecoli_10K_methylated_1_val_1_bismark_bt2_pe.deduplicated_splitting_report.txt:md5,5ce32b88b28766d6fa0bf91ea9df77d6", - "SRR389222_sub1_trimmed_bismark_bt2.deduplicated_splitting_report.txt:md5,d70ee229a29b68db8634fa7d568b7c53", - "SRR389222_sub2_trimmed_bismark_bt2.deduplicated_splitting_report.txt:md5,3038a90a6e513c3b1c0de540439eb101", - "genome_results.txt:md5,7886cc1a96ee892e49898b0d69ed66f2", - "genome_results.txt:md5,79287f69ff6c8a308f0bb988c97f0e15", - "genome_results.txt:md5,29e911b75d7160e964530e9607110164" + "Ecoli_10K.NOMe.CpG.cov.gz:md5,b172ec70bfb6607a5704c68ed27dc8e4", + "Ecoli_10K.NOMe.GpC.cov.gz:md5,c975d1cbd714f79ce900378604b460b5", + "SRR389222.NOMe.CpG.cov.gz:md5,c86cd4e0523987bbb18191aeb2d2ecfd", + "SRR389222.NOMe.GpC.cov.gz:md5,bdd5bd0a9fc8be7cbd22d7fe302e8f17", + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bam:md5,a7464c83416ba057387df5d85b1bc1fe", + "SRR389222_trimmed_bismark_bt2.deduplicated.bam:md5,7dba45955ae74159596a6ab41a9dcc87", + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bedGraph.gz:md5,6d631d8999657816e569a7a896f423d5", + "SRR389222_trimmed_bismark_bt2.deduplicated.bedGraph.gz:md5,4a1bee24f279542dad02b167fabc6997", + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.M-bias.txt:md5,29f3b882a51b63ce77d3d9c69b0e5f85", + "SRR389222_trimmed_bismark_bt2.deduplicated.M-bias.txt:md5,bc48b8895f9ce84205a25899cf551624", + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bismark.cov.gz:md5,5a358982536d476e962319b6656441da", + "SRR389222_trimmed_bismark_bt2.deduplicated.bismark.cov.gz:md5,b08b8d4dc026106345ca6108e27ed601", + [ + "CHG_OB_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,bca8572c7cd3cd45e148ba722ad4b12d", + "CHG_OB_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,b0f6e9284b65d1bf3c813008c08656cc", + "CHG_OT_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,7f49ecab1843458c28c3d6fe6a85149e", + "CHG_OT_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,ddc200fe98155bf88be3d98073a37238", + "CHH_OB_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,e67409a20a141077edc1dc61972bb278", + "CHH_OB_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,aca84c4d6fffb7bf72f4dcd4371dc89b", + "CHH_OT_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,d173808471dbb7c50ef43eb1f5f29faa", + "CHH_OT_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,a23e78b714eb1ef1810714d29557c620", + "CpG_OB_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,c3d32d42c00d94ea8322487aa0a20787", + "CpG_OB_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,0039a8c3f8971a5a99bc58bc1511fa0d", + "CpG_OT_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,6dfc57a2892d7cd3bebb7cbc0878196b", + "CpG_OT_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,288062a6b71f04688afad75dcd2230f9" + ], + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated_splitting_report.txt:md5,79ebef1c474ff5bdb5f79b955208bb04", + "SRR389222_trimmed_bismark_bt2.deduplicated_splitting_report.txt:md5,1c4a4288b3bcf1bbaa6b99e3c4b53ce9", + "SRR389222.merged.fastq.gz:md5,ba5df0639e25988059a6f5bf309dbb6e", + "genome_results.txt:md5,1e01c188f34b7d385e8b16156ab2b93e", + "genome_results.txt:md5,b99d4cfd82d21ac09ccb72865f9b3960" ], - "timestamp": "2023-06-01T02:27:54+0000" + "timestamp": "2023-08-28T08:46:48+0000" }, "single_end_rrbs_software_versions": { "content": [ - "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, SAMPLESHEET_CHECK={python=3.8.3}, Workflow={nf-core/methylseq=2.5.0dev}}" + "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, Workflow={nf-core/methylseq=2.5.0dev}}" + ], + "timestamp": "2023-08-28T08:46:48+0000" + }, + "single_end__nomeseq_software_versions": { + "content": [ + "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" ], - "timestamp": "2023-06-01T02:27:54+0000" + "timestamp": "2023-08-28T08:46:48+0000" + }, + "clip_r1_software_versions": { + "content": [ + "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" + ], + "timestamp": "2023-08-28T08:46:48+0000" }, "single_end": { "content": [ - "Ecoli_10K_methylated_1_val_1_bismark_bt2_pe.deduplicated_splitting_report.txt:md5,5ce32b88b28766d6fa0bf91ea9df77d6", - "SRR389222_sub1_trimmed_bismark_bt2.deduplicated_splitting_report.txt:md5,d70ee229a29b68db8634fa7d568b7c53", - "SRR389222_sub2_trimmed_bismark_bt2.deduplicated_splitting_report.txt:md5,3038a90a6e513c3b1c0de540439eb101", - "genome_results.txt:md5,7886cc1a96ee892e49898b0d69ed66f2", - "genome_results.txt:md5,79287f69ff6c8a308f0bb988c97f0e15", - "genome_results.txt:md5,29e911b75d7160e964530e9607110164" + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bam:md5,a7464c83416ba057387df5d85b1bc1fe", + "SRR389222_trimmed_bismark_bt2.deduplicated.bam:md5,7dba45955ae74159596a6ab41a9dcc87", + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bedGraph.gz:md5,66af42e52cdcaf5ceabddb33c9045a4d", + "SRR389222_trimmed_bismark_bt2.deduplicated.bedGraph.gz:md5,60bf00418d5e2ede8740e3cba6c6ef61", + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.M-bias.txt:md5,29f3b882a51b63ce77d3d9c69b0e5f85", + "SRR389222_trimmed_bismark_bt2.deduplicated.M-bias.txt:md5,bc48b8895f9ce84205a25899cf551624", + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bismark.cov.gz:md5,ef5178734cdbba3326e22f8459b4db48", + "SRR389222_trimmed_bismark_bt2.deduplicated.bismark.cov.gz:md5,0bb6dd26908e239f695105230564b59b", + [ + "CHG_OB_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,bca8572c7cd3cd45e148ba722ad4b12d", + "CHG_OB_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,b0f6e9284b65d1bf3c813008c08656cc", + "CHG_OT_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,7f49ecab1843458c28c3d6fe6a85149e", + "CHG_OT_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,ddc200fe98155bf88be3d98073a37238", + "CHH_OB_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,e67409a20a141077edc1dc61972bb278", + "CHH_OB_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,aca84c4d6fffb7bf72f4dcd4371dc89b", + "CHH_OT_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,d173808471dbb7c50ef43eb1f5f29faa", + "CHH_OT_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,a23e78b714eb1ef1810714d29557c620", + "CpG_OB_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,c3d32d42c00d94ea8322487aa0a20787", + "CpG_OB_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,0039a8c3f8971a5a99bc58bc1511fa0d", + "CpG_OT_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,6dfc57a2892d7cd3bebb7cbc0878196b", + "CpG_OT_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,288062a6b71f04688afad75dcd2230f9" + ], + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated_splitting_report.txt:md5,79ebef1c474ff5bdb5f79b955208bb04", + "SRR389222_trimmed_bismark_bt2.deduplicated_splitting_report.txt:md5,1c4a4288b3bcf1bbaa6b99e3c4b53ce9", + [ + [ + [ + "BS_CT.1.bt2:md5,d53bef7d951c7d08e327944581c911eb", + "BS_CT.2.bt2:md5,752a03fc364115fc910e5a28ae154382", + "BS_CT.3.bt2:md5,b41e72eefad74e8ede411c78a5bd5dee", + "BS_CT.4.bt2:md5,02b3d1855a67fd9cbb4c411406a22fde", + "BS_CT.rev.1.bt2:md5,52ae603fff473b3b25eecd36c533edb9", + "BS_CT.rev.2.bt2:md5,0e290e05f7dae065cae54e29ed97afe5", + "genome_mfa.CT_conversion.fa:md5,4dd181b65f1f3549f4132c9a3759eee8" + ], + [ + "BS_GA.1.bt2:md5,9aff51b1712758b891b0c427a988977f", + "BS_GA.2.bt2:md5,579241d95941538b2e75bbdb6cfaa73d", + "BS_GA.3.bt2:md5,b41e72eefad74e8ede411c78a5bd5dee", + "BS_GA.4.bt2:md5,6b64fa496ffa2af2af235e1c87f06a25", + "BS_GA.rev.1.bt2:md5,dabf2d6f80ba7e8fc96dfdc203f6bbfd", + "BS_GA.rev.2.bt2:md5,fac2f8b39b0e15dec7aa79a0ecf12b49", + "genome_mfa.GA_conversion.fa:md5,3dee732bc344fd620c3a7322f52c6a5f" + ] + ], + "genome.fa:md5,923a0a268ad29fee3c3437d00f9970de" + ], + "genome_results.txt:md5,1e01c188f34b7d385e8b16156ab2b93e", + "genome_results.txt:md5,b99d4cfd82d21ac09ccb72865f9b3960" ], - "timestamp": "2023-06-01T02:27:54+0000" + "timestamp": "2023-08-28T08:46:48+0000" }, "single_end_rrbs": { "content": [ + "Ecoli_10K_methylated_R1_bismark_bt2_pe.bam:md5,1497e3a06ee045cb82f834ddb4bcfe88", + "SRR389222.merged_bismark_bt2.bam:md5,c3e94ff13a934e0c78ebb6d40f7c8230", + "Ecoli_10K_methylated_R1_bismark_bt2_pe.bedGraph.gz:md5,66af42e52cdcaf5ceabddb33c9045a4d", + "SRR389222.merged_bismark_bt2.bedGraph.gz:md5,5d87f42769268bceb35b3341aa4dc92f", + "Ecoli_10K_methylated_R1_bismark_bt2_pe.M-bias.txt:md5,29f3b882a51b63ce77d3d9c69b0e5f85", + "SRR389222.merged_bismark_bt2.M-bias.txt:md5,514f544046333337f0f74b7386b8afa6", + "Ecoli_10K_methylated_R1_bismark_bt2_pe.bismark.cov.gz:md5,ef5178734cdbba3326e22f8459b4db48", + "SRR389222.merged_bismark_bt2.bismark.cov.gz:md5,b46638fd5f36fa4bce5f4f7b7247d995", + [ + "CHG_OB_Ecoli_10K_methylated_R1_bismark_bt2_pe.txt.gz:md5,bca8572c7cd3cd45e148ba722ad4b12d", + "CHG_OB_SRR389222.merged_bismark_bt2.txt.gz:md5,3fcc7974fd6c5cbacf231835f58d949b", + "CHG_OT_Ecoli_10K_methylated_R1_bismark_bt2_pe.txt.gz:md5,7f49ecab1843458c28c3d6fe6a85149e", + "CHG_OT_SRR389222.merged_bismark_bt2.txt.gz:md5,d80c75d6eb49f629c9f5f4c2e63588aa", + "CHH_OB_Ecoli_10K_methylated_R1_bismark_bt2_pe.txt.gz:md5,e67409a20a141077edc1dc61972bb278", + "CHH_OB_SRR389222.merged_bismark_bt2.txt.gz:md5,2fb870b779750951bec579ce7562736e", + "CHH_OT_Ecoli_10K_methylated_R1_bismark_bt2_pe.txt.gz:md5,d173808471dbb7c50ef43eb1f5f29faa", + "CHH_OT_SRR389222.merged_bismark_bt2.txt.gz:md5,8fea7767cfe903f9671a506feaa7a8a6", + "CpG_OB_Ecoli_10K_methylated_R1_bismark_bt2_pe.txt.gz:md5,c3d32d42c00d94ea8322487aa0a20787", + "CpG_OB_SRR389222.merged_bismark_bt2.txt.gz:md5,6537b18418e62410d9ae617480702c54", + "CpG_OT_Ecoli_10K_methylated_R1_bismark_bt2_pe.txt.gz:md5,6dfc57a2892d7cd3bebb7cbc0878196b", + "CpG_OT_SRR389222.merged_bismark_bt2.txt.gz:md5,3450512dc718e26edf13ff870cf3b159" + ], "Ecoli_10K_methylated_R1_bismark_bt2_pe_splitting_report.txt:md5,fa089f6146df9667862970b6ddc998b0", - "SRR389222_sub1_bismark_bt2_splitting_report.txt:md5,f59eac7a30ec7f1f690aac921a5591c0", - "SRR389222_sub2.merged_bismark_bt2_splitting_report.txt:md5,43ca6c76e47ce2eb1c8dd6027475b5a6", - "genome_results.txt:md5,41becdcecee6ebbdd46f472629731892", - "genome_results.txt:md5,7a86634fd1c768d8302e071088641815", - "genome_results.txt:md5,9e9b6841f3b3a46a299c61c516aa125e" + "SRR389222.merged_bismark_bt2_splitting_report.txt:md5,0ece57f8fc3aa659d2f0b7a09cf48398", + [ + [ + [ + "BS_CT.1.bt2:md5,d53bef7d951c7d08e327944581c911eb", + "BS_CT.2.bt2:md5,752a03fc364115fc910e5a28ae154382", + "BS_CT.3.bt2:md5,b41e72eefad74e8ede411c78a5bd5dee", + "BS_CT.4.bt2:md5,02b3d1855a67fd9cbb4c411406a22fde", + "BS_CT.rev.1.bt2:md5,52ae603fff473b3b25eecd36c533edb9", + "BS_CT.rev.2.bt2:md5,0e290e05f7dae065cae54e29ed97afe5", + "genome_mfa.CT_conversion.fa:md5,4dd181b65f1f3549f4132c9a3759eee8" + ], + [ + "BS_GA.1.bt2:md5,9aff51b1712758b891b0c427a988977f", + "BS_GA.2.bt2:md5,579241d95941538b2e75bbdb6cfaa73d", + "BS_GA.3.bt2:md5,b41e72eefad74e8ede411c78a5bd5dee", + "BS_GA.4.bt2:md5,6b64fa496ffa2af2af235e1c87f06a25", + "BS_GA.rev.1.bt2:md5,dabf2d6f80ba7e8fc96dfdc203f6bbfd", + "BS_GA.rev.2.bt2:md5,fac2f8b39b0e15dec7aa79a0ecf12b49", + "genome_mfa.GA_conversion.fa:md5,3dee732bc344fd620c3a7322f52c6a5f" + ] + ], + "genome.fa:md5,923a0a268ad29fee3c3437d00f9970de" + ], + "genome_results.txt:md5,b6ba7868b12971aaad0d4a04e25acd0b", + "genome_results.txt:md5,f0d293867800a75becf2583c23729083" + ], + "timestamp": "2023-08-28T08:46:48+0000" + }, + "clip_r1": { + "content": [ + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bam:md5,388bb71e1e52628823e8b590d37cd665", + "SRR389222_trimmed_bismark_bt2.deduplicated.bam:md5,1bfe463dabf8727992e3ff6c19d8e7c1", + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bedGraph.gz:md5,4fbac770e7bf6b93e972d7e5bc494aac", + "SRR389222_trimmed_bismark_bt2.deduplicated.bedGraph.gz:md5,7b7535a28d655edaa94bcfa79957731a", + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.M-bias.txt:md5,83a004a3d957cf95f25933bcd828a8d4", + "SRR389222_trimmed_bismark_bt2.deduplicated.M-bias.txt:md5,90a6b76d41112c6de391d3a017638d95", + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.bismark.cov.gz:md5,9dc43af95c865440be68a4a41634f6c3", + "SRR389222_trimmed_bismark_bt2.deduplicated.bismark.cov.gz:md5,da2acc1e94842feee25e282575b74ce2", + [ + "CHG_OB_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,bd15affb231e6fa69f3daef1993e732f", + "CHG_OB_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,8175e992f5cd9c3cd9c2d82b36c3231b", + "CHG_OT_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,f5fee467014e215c43569efcc696a6e0", + "CHG_OT_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,9918a6c806dcb92a95e3806e8aae30f7", + "CHH_OB_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,0c0f91367e3fd1d14710604af2cfeb1c", + "CHH_OB_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,52dcf6c1e4e0cf4aaee2c4e42aad190f", + "CHH_OT_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,8befa0112f299724b60eb6c5de1cdf1f", + "CHH_OT_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,c4c864ee34ebb523d3c424b787ee9a3a", + "CpG_OB_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,50f969a02e2a50f140dedb90cdc3718d", + "CpG_OB_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,e066703e693e77ef934f64f16013c431", + "CpG_OT_Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated.txt.gz:md5,af7b19d0658a58a3a6f2632d9c0276f4", + "CpG_OT_SRR389222_trimmed_bismark_bt2.deduplicated.txt.gz:md5,b3c76b857baf4f2236137466b474cdb8" + ], + "Ecoli_10K_1_val_1_bismark_bt2_pe.deduplicated_splitting_report.txt:md5,373ac926ba4ceae1c4826f5ea4b3ada6", + "SRR389222_trimmed_bismark_bt2.deduplicated_splitting_report.txt:md5,9a1a5d1e6722dda9e8a1953a01c415d0", + "SRR389222.merged.fastq.gz:md5,ba5df0639e25988059a6f5bf309dbb6e", + "genome_results.txt:md5,72bdf73fe97711a2ba75b5c59f3a5637", + "genome_results.txt:md5,5631f1632df00985946641cfc1601633" ], - "timestamp": "2023-06-01T02:27:54+0000" + "timestamp": "2023-08-28T08:46:48+0000" } } \ No newline at end of file diff --git a/tests/pipeline/bismark_hisat/main.nf.test b/tests/pipeline/bismark_hisat/main.nf.test index a368b722..e4bd6217 100644 --- a/tests/pipeline/bismark_hisat/main.nf.test +++ b/tests/pipeline/bismark_hisat/main.nf.test @@ -28,14 +28,34 @@ nextflow_pipeline { assertAll( { assert workflow.success }, - { assert snapshot(path("$outputDir/bismark_hisat/methylation_calls/splitting_report/Ecoli_10K_methylated_1_val_1_bismark_hisat2_pe.deduplicated_splitting_report.txt"), - path("$outputDir/bismark_hisat/methylation_calls/splitting_report/SRR389222_sub1_trimmed_bismark_hisat2.deduplicated_splitting_report.txt"), - path("$outputDir/bismark_hisat/methylation_calls/splitting_report/SRR389222_sub2_trimmed_bismark_hisat2.deduplicated_splitting_report.txt"), - path("$outputDir/qualimap/Ecoli_10K_methylated/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub1/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub2/genome_results.txt")).match("single_end") }, + { assert snapshot(path("$outputDir/bismark_hisat/deduplicated/Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.bam"), + path("$outputDir/bismark_hisat/deduplicated/SRR389222_trimmed_bismark_hisat2.deduplicated.bam"), + path("$outputDir/bismark_hisat/methylation_calls/bedGraph/Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.bedGraph.gz"), + path("$outputDir/bismark_hisat/methylation_calls/bedGraph/SRR389222_trimmed_bismark_hisat2.deduplicated.bedGraph.gz"), + path("$outputDir/bismark_hisat/methylation_calls/mbias/Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.M-bias.txt"), + path("$outputDir/bismark_hisat/methylation_calls/mbias/SRR389222_trimmed_bismark_hisat2.deduplicated.M-bias.txt"), + path("$outputDir/bismark_hisat/methylation_calls/methylation_calls/").list(), + path("$outputDir/bismark_hisat/methylation_calls/methylation_coverage/Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.bismark.cov.gz"), + path("$outputDir/bismark_hisat/methylation_calls/methylation_coverage/SRR389222_trimmed_bismark_hisat2.deduplicated.bismark.cov.gz"), + path("$outputDir/bismark_hisat/methylation_calls/splitting_report/Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated_splitting_report.txt"), + path("$outputDir/bismark_hisat/methylation_calls/splitting_report/SRR389222_trimmed_bismark_hisat2.deduplicated_splitting_report.txt"), + path("$outputDir/cat/SRR389222.merged.fastq.gz"), + path("$outputDir/qualimap/Ecoli_10K/genome_results.txt"), + path("$outputDir/qualimap/SRR389222/genome_results.txt")).match("single_end") }, { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end_software_versions") }, - { assert new File("$outputDir/bismark_hisat/summary/bismark_summary_report.txt").exists() } + { assert new File("$outputDir/bismark_hisat/alignments/logs/Ecoli_10K_1_val_1_bismark_hisat2_PE_report.txt").exists() }, + { assert new File("$outputDir/bismark_hisat/alignments/logs/SRR389222_trimmed_bismark_hisat2_SE_report.txt").exists() }, + { assert new File("$outputDir/bismark_hisat/reports/Ecoli_10K_1_val_1_bismark_hisat2_PE_report.html").exists() }, + { assert new File("$outputDir/bismark_hisat/reports/SRR389222_trimmed_bismark_hisat2_SE_report.html").exists() }, + { assert new File("$outputDir/bismark_hisat/summary/bismark_summary_report.html").exists() }, + { assert new File("$outputDir/bismark_hisat/summary/bismark_summary_report.txt").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_1_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_2_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/SRR389222_fastqc.html").exists() }, + { assert new File("$outputDir/multiqc/bismark_hisat/multiqc_report.html").exists() }, + { assert new File("$outputDir/trimgalore/logs/Ecoli_10K_1.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/trimgalore/logs/Ecoli_10K_2.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/trimgalore/logs/SRR389222.fastq.gz_trimming_report.txt").exists() } ) } } @@ -70,14 +90,31 @@ nextflow_pipeline { then { assertAll( { assert workflow.success }, - { assert snapshot(path("$outputDir/bismark_hisat/methylation_calls/splitting_report/Ecoli_10K_methylated_R1_bismark_hisat2_pe_splitting_report.txt"), - path("$outputDir/bismark_hisat/methylation_calls/splitting_report/SRR389222_sub1_bismark_hisat2_splitting_report.txt"), - path("$outputDir/bismark_hisat/methylation_calls/splitting_report/SRR389222_sub2.merged_bismark_hisat2_splitting_report.txt"), - path("$outputDir/qualimap/Ecoli_10K_methylated/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub1/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub2/genome_results.txt")).match("single_end_rrbs") }, + { assert snapshot(path("$outputDir/bismark_hisat/alignments/Ecoli_10K_methylated_R1_bismark_hisat2_pe.bam"), + path("$outputDir/bismark_hisat/alignments/SRR389222.merged_bismark_hisat2.bam"), + path("$outputDir/bismark_hisat/methylation_calls/bedGraph/Ecoli_10K_methylated_R1_bismark_hisat2_pe.bedGraph.gz"), + path("$outputDir/bismark_hisat/methylation_calls/bedGraph/SRR389222.merged_bismark_hisat2.bedGraph.gz"), + path("$outputDir/bismark_hisat/methylation_calls/mbias/Ecoli_10K_methylated_R1_bismark_hisat2_pe.M-bias.txt"), + path("$outputDir/bismark_hisat/methylation_calls/mbias/SRR389222.merged_bismark_hisat2.M-bias.txt"), + path("$outputDir/bismark_hisat/methylation_calls/methylation_calls/").list(), + path("$outputDir/bismark_hisat/methylation_calls/methylation_coverage/Ecoli_10K_methylated_R1_bismark_hisat2_pe.bismark.cov.gz"), + path("$outputDir/bismark_hisat/methylation_calls/methylation_coverage/SRR389222.merged_bismark_hisat2.bismark.cov.gz"), + path("$outputDir/bismark_hisat/methylation_calls/splitting_report/Ecoli_10K_methylated_R1_bismark_hisat2_pe_splitting_report.txt"), + path("$outputDir/bismark_hisat/methylation_calls/splitting_report/SRR389222.merged_bismark_hisat2_splitting_report.txt"), + path("$outputDir/cat/SRR389222.merged.fastq.gz"), + path("$outputDir/qualimap/Ecoli_10K/genome_results.txt"), + path("$outputDir/qualimap/SRR389222/genome_results.txt")).match("single_end_rrbs") }, { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end_rrbs_software_versions") }, - { assert new File("$outputDir/bismark_hisat/summary/bismark_summary_report.txt").exists() } + { assert new File("$outputDir/bismark_hisat/alignments/logs/Ecoli_10K_methylated_R1_bismark_hisat2_PE_report.txt").exists() }, + { assert new File("$outputDir/bismark_hisat/alignments/logs/SRR389222.merged_bismark_hisat2_SE_report.txt").exists() }, + { assert new File("$outputDir/bismark_hisat/reports/Ecoli_10K_methylated_R1_bismark_hisat2_PE_report.html").exists() }, + { assert new File("$outputDir/bismark_hisat/reports/SRR389222.merged_bismark_hisat2_SE_report.html").exists() }, + { assert new File("$outputDir/bismark_hisat/summary/bismark_summary_report.html").exists() }, + { assert new File("$outputDir/bismark_hisat/summary/bismark_summary_report.txt").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_1_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_2_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/SRR389222_fastqc.html").exists() }, + { assert new File("$outputDir/multiqc/bismark_hisat/multiqc_report.html").exists() } ) } } diff --git a/tests/pipeline/bismark_hisat/main.nf.test.snap b/tests/pipeline/bismark_hisat/main.nf.test.snap index aab97792..f1fc2fe3 100644 --- a/tests/pipeline/bismark_hisat/main.nf.test.snap +++ b/tests/pipeline/bismark_hisat/main.nf.test.snap @@ -1,36 +1,78 @@ { "single_end_software_versions": { "content": [ - "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, SAMPLESHEET_CHECK={python=3.8.3}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" + "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" ], - "timestamp": "2023-06-01T02:43:30+0000" + "timestamp": "2023-08-28T10:04:42+0000" }, "single_end_rrbs_software_versions": { "content": [ - "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, SAMPLESHEET_CHECK={python=3.8.3}, Workflow={nf-core/methylseq=2.5.0dev}}" + "{BISMARK_ALIGN={bismark=0.24.0}, BISMARK_GENOMEPREPARATION={bismark=0.24.0}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, Workflow={nf-core/methylseq=2.5.0dev}}" ], - "timestamp": "2023-06-01T02:43:30+0000" + "timestamp": "2023-08-28T10:04:42+0000" }, "single_end": { "content": [ - "Ecoli_10K_methylated_1_val_1_bismark_hisat2_pe.deduplicated_splitting_report.txt:md5,bdec8746a4f29c56ddbe37a92f7d35dd", - "SRR389222_sub1_trimmed_bismark_hisat2.deduplicated_splitting_report.txt:md5,4020063dd8610b58b7b39c3ca62cef17", - "SRR389222_sub2_trimmed_bismark_hisat2.deduplicated_splitting_report.txt:md5,4db2155fdfae1cb9c7c758edba256e2e", - "genome_results.txt:md5,cd5d3b03821c038eb3bda24beb3ae938", - "genome_results.txt:md5,9956ed1dcf51e6975f4a6ab8fe156aba", - "genome_results.txt:md5,1133ea5d1376389c6a17def89d2e90ec" + "Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.bam:md5,9e9b4adfeeb716e24ecba0bfad39c2e3", + "SRR389222_trimmed_bismark_hisat2.deduplicated.bam:md5,aa60cf9dcf302c185b12ced6f302a06e", + "Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.bedGraph.gz:md5,539b06719ca6dcccaf2b86d8be571ace", + "SRR389222_trimmed_bismark_hisat2.deduplicated.bedGraph.gz:md5,dba86d0f60ad88aaeef1970ceef8376b", + "Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.M-bias.txt:md5,5fd8655f4b9dba2249a52b769fe50faf", + "SRR389222_trimmed_bismark_hisat2.deduplicated.M-bias.txt:md5,b19356395d4ae1ad83bd3ec38276e580", + [ + "CHG_OB_Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.txt.gz:md5,c2144bcfb7850b8c10bb8296dd2e09c1", + "CHG_OB_SRR389222_trimmed_bismark_hisat2.deduplicated.txt.gz:md5,b0f6e9284b65d1bf3c813008c08656cc", + "CHG_OT_Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.txt.gz:md5,7f49ecab1843458c28c3d6fe6a85149e", + "CHG_OT_SRR389222_trimmed_bismark_hisat2.deduplicated.txt.gz:md5,5813137cea214c7759598ca442f29d47", + "CHH_OB_Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.txt.gz:md5,4e8f5b27fbb933c572f269688004be38", + "CHH_OB_SRR389222_trimmed_bismark_hisat2.deduplicated.txt.gz:md5,aca84c4d6fffb7bf72f4dcd4371dc89b", + "CHH_OT_Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.txt.gz:md5,d173808471dbb7c50ef43eb1f5f29faa", + "CHH_OT_SRR389222_trimmed_bismark_hisat2.deduplicated.txt.gz:md5,1018c276fa14900e7b1edad0e23fc7ff", + "CpG_OB_Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.txt.gz:md5,3f58d13a3b47d639696dbb4478a39488", + "CpG_OB_SRR389222_trimmed_bismark_hisat2.deduplicated.txt.gz:md5,0039a8c3f8971a5a99bc58bc1511fa0d", + "CpG_OT_Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.txt.gz:md5,6dfc57a2892d7cd3bebb7cbc0878196b", + "CpG_OT_SRR389222_trimmed_bismark_hisat2.deduplicated.txt.gz:md5,801c0dba9ca584d9c804a4254d7c4ea6" + ], + "Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated.bismark.cov.gz:md5,474c1291d09b023e91ed892b5a09ba80", + "SRR389222_trimmed_bismark_hisat2.deduplicated.bismark.cov.gz:md5,e58cba79f419cb411a77b656173d48ea", + "Ecoli_10K_1_val_1_bismark_hisat2_pe.deduplicated_splitting_report.txt:md5,a5dc04c52facdb5221a06ae7f3bca2e4", + "SRR389222_trimmed_bismark_hisat2.deduplicated_splitting_report.txt:md5,1f792e1fddb17140947f14008e1f9ffd", + "SRR389222.merged.fastq.gz:md5,ba5df0639e25988059a6f5bf309dbb6e", + "genome_results.txt:md5,f272f759bfed7e8a30ec2719e0b518aa", + "genome_results.txt:md5,7706d3790aee0e9244c490941ecd394f" ], - "timestamp": "2023-06-01T02:43:30+0000" + "timestamp": "2023-08-28T10:04:42+0000" }, "single_end_rrbs": { "content": [ + "Ecoli_10K_methylated_R1_bismark_hisat2_pe.bam:md5,53c34edee0bc7f34c9f4e9a3685dd706", + "SRR389222.merged_bismark_hisat2.bam:md5,204123a5f7cd77cba3a90b904443c7eb", + "Ecoli_10K_methylated_R1_bismark_hisat2_pe.bedGraph.gz:md5,539b06719ca6dcccaf2b86d8be571ace", + "SRR389222.merged_bismark_hisat2.bedGraph.gz:md5,2b41ebc929eec351e21a16eec6f8fdd9", + "Ecoli_10K_methylated_R1_bismark_hisat2_pe.M-bias.txt:md5,5fd8655f4b9dba2249a52b769fe50faf", + "SRR389222.merged_bismark_hisat2.M-bias.txt:md5,ea90b0495446d03e375aad42d598a9f9", + [ + "CHG_OB_Ecoli_10K_methylated_R1_bismark_hisat2_pe.txt.gz:md5,c2144bcfb7850b8c10bb8296dd2e09c1", + "CHG_OB_SRR389222.merged_bismark_hisat2.txt.gz:md5,3fcc7974fd6c5cbacf231835f58d949b", + "CHG_OT_Ecoli_10K_methylated_R1_bismark_hisat2_pe.txt.gz:md5,7f49ecab1843458c28c3d6fe6a85149e", + "CHG_OT_SRR389222.merged_bismark_hisat2.txt.gz:md5,e924ba0137252d4b470532cfc36524c2", + "CHH_OB_Ecoli_10K_methylated_R1_bismark_hisat2_pe.txt.gz:md5,4e8f5b27fbb933c572f269688004be38", + "CHH_OB_SRR389222.merged_bismark_hisat2.txt.gz:md5,2fb870b779750951bec579ce7562736e", + "CHH_OT_Ecoli_10K_methylated_R1_bismark_hisat2_pe.txt.gz:md5,d173808471dbb7c50ef43eb1f5f29faa", + "CHH_OT_SRR389222.merged_bismark_hisat2.txt.gz:md5,6e1d89e988f10fa528398b117a554fb1", + "CpG_OB_Ecoli_10K_methylated_R1_bismark_hisat2_pe.txt.gz:md5,3f58d13a3b47d639696dbb4478a39488", + "CpG_OB_SRR389222.merged_bismark_hisat2.txt.gz:md5,6537b18418e62410d9ae617480702c54", + "CpG_OT_Ecoli_10K_methylated_R1_bismark_hisat2_pe.txt.gz:md5,6dfc57a2892d7cd3bebb7cbc0878196b", + "CpG_OT_SRR389222.merged_bismark_hisat2.txt.gz:md5,b07add9bb5ebc7d404e1505deb960654" + ], + "Ecoli_10K_methylated_R1_bismark_hisat2_pe.bismark.cov.gz:md5,474c1291d09b023e91ed892b5a09ba80", + "SRR389222.merged_bismark_hisat2.bismark.cov.gz:md5,626edb040f82e57c1f521bdb72618407", "Ecoli_10K_methylated_R1_bismark_hisat2_pe_splitting_report.txt:md5,76868c2015864a3f7c2b4cd1738e4765", - "SRR389222_sub1_bismark_hisat2_splitting_report.txt:md5,754ed7bf4d75acee466c48c05a11d331", - "SRR389222_sub2.merged_bismark_hisat2_splitting_report.txt:md5,0629e1f8b4727efe8fd69500783eec61", - "genome_results.txt:md5,3afd1eb7d4dc72a05e4d4de887d791e3", - "genome_results.txt:md5,58a2aeeb5eacca4c766bb23fee8f9013", - "genome_results.txt:md5,473022a29cf12d97e75451a4eea67c02" + "SRR389222.merged_bismark_hisat2_splitting_report.txt:md5,4a9e54ffb48c9bb1e5ac33aa77b25f5c", + "SRR389222.merged.fastq.gz:md5,ba5df0639e25988059a6f5bf309dbb6e", + "genome_results.txt:md5,13a70a3885acd9d55014aa1ad66e2bbb", + "genome_results.txt:md5,ae5b10e9a3ffa1ac7a4f4e736228ec49" ], - "timestamp": "2023-06-01T02:43:30+0000" + "timestamp": "2023-08-28T10:04:42+0000" } } \ No newline at end of file diff --git a/tests/pipeline/bwameth/main.nf.test b/tests/pipeline/bwameth/main.nf.test index 95d783c0..65b25dec 100644 --- a/tests/pipeline/bwameth/main.nf.test +++ b/tests/pipeline/bwameth/main.nf.test @@ -28,16 +28,32 @@ nextflow_pipeline { assertAll( { assert workflow.success }, - { assert snapshot(path("$outputDir/bwameth/alignments/samtools_stats/Ecoli_10K_methylated.flagstat"), - path("$outputDir/bwameth/alignments/samtools_stats/SRR389222_sub1.flagstat"), - path("$outputDir/bwameth/alignments/samtools_stats/SRR389222_sub2.flagstat"), - path("$outputDir/methyldackel/Ecoli_10K_methylated.markdup.sorted_CpG.bedGraph"), - path("$outputDir/methyldackel/SRR389222_sub1.markdup.sorted_CpG.bedGraph"), - path("$outputDir/methyldackel/SRR389222_sub2.markdup.sorted_CpG.bedGraph"), - path("$outputDir/qualimap/Ecoli_10K_methylated/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub1/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub2/genome_results.txt")).match("single_end") }, - { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end_software_versions") } + { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end_software_versions") }, + { assert snapshot(path("$outputDir/bwameth/alignments/samtools_stats/Ecoli_10K.flagstat"), + path("$outputDir/bwameth/alignments/samtools_stats/Ecoli_10K.stats"), + path("$outputDir/bwameth/alignments/samtools_stats/SRR389222.flagstat"), + path("$outputDir/bwameth/alignments/samtools_stats/SRR389222.stats"), + path("$outputDir/bwameth/deduplicated/Ecoli_10K.markdup.sorted.bam"), + path("$outputDir/bwameth/deduplicated/Ecoli_10K.markdup.sorted.bam.bai"), + path("$outputDir/bwameth/deduplicated/SRR389222.markdup.sorted.bam"), + path("$outputDir/bwameth/deduplicated/SRR389222.markdup.sorted.bam.bai"), + path("$outputDir/bwameth/reference_genome/").list(), + path("$outputDir/cat/SRR389222.merged.fastq.gz"), + path("$outputDir/methyldackel/Ecoli_10K.markdup.sorted_CpG.bedGraph"), + path("$outputDir/methyldackel/SRR389222.markdup.sorted_CpG.bedGraph"), + path("$outputDir/methyldackel/mbias/Ecoli_10K.mbias.txt"), + path("$outputDir/methyldackel/mbias/SRR389222.mbias.txt"), + path("$outputDir/qualimap/Ecoli_10K/genome_results.txt"), + path("$outputDir/qualimap/SRR389222/genome_results.txt")).match("single_end") }, + { assert new File("$outputDir/fastqc/Ecoli_10K_1_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_2_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/SRR389222_fastqc.html").exists() }, + { assert new File("$outputDir/multiqc/bwameth/multiqc_report.html").exists() }, + { assert new File("$outputDir/trimgalore/logs/Ecoli_10K_1.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/trimgalore/logs/Ecoli_10K_2.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/trimgalore/logs/SRR389222.fastq.gz_trimming_report.txt").exists() }, + { assert new File("$outputDir/bwameth/deduplicated/picard_metrics/Ecoli_10K.markdup.sorted.MarkDuplicates.metrics.txt").exists() }, + { assert new File("$outputDir/bwameth/deduplicated/picard_metrics/SRR389222.markdup.sorted.MarkDuplicates.metrics.txt").exists() } ) } } @@ -73,16 +89,23 @@ nextflow_pipeline { then { assertAll( { assert workflow.success }, - { assert snapshot(path("$outputDir/bwameth/alignments/samtools_stats/Ecoli_10K_methylated.flagstat"), - path("$outputDir/bwameth/alignments/samtools_stats/SRR389222_sub1.flagstat"), - path("$outputDir/bwameth/alignments/samtools_stats/SRR389222_sub2.flagstat"), - path("$outputDir/methyldackel/Ecoli_10K_methylated.sorted_CpG.bedGraph"), - path("$outputDir/methyldackel/SRR389222_sub1.sorted_CpG.bedGraph"), - path("$outputDir/methyldackel/SRR389222_sub2.sorted_CpG.bedGraph"), - path("$outputDir/qualimap/Ecoli_10K_methylated/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub1/genome_results.txt"), - path("$outputDir/qualimap/SRR389222_sub2/genome_results.txt")).match("single_end_rrbs") }, - { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end_rrbs_software_versions") } + { assert snapshot(UTILS.removeNextflowVersion("$outputDir")).match("single_end_rrbs_software_versions") }, + { assert snapshot(path("$outputDir/bwameth/alignments/samtools_stats/Ecoli_10K.flagstat"), + path("$outputDir/bwameth/alignments/samtools_stats/Ecoli_10K.stats"), + path("$outputDir/bwameth/alignments/samtools_stats/SRR389222.flagstat"), + path("$outputDir/bwameth/alignments/samtools_stats/SRR389222.stats"), + path("$outputDir/bwameth/reference_genome/").list(), + path("$outputDir/cat/SRR389222.merged.fastq.gz"), + path("$outputDir/methyldackel/Ecoli_10K.sorted_CpG.bedGraph"), + path("$outputDir/methyldackel/SRR389222.sorted_CpG.bedGraph"), + path("$outputDir/methyldackel/mbias/Ecoli_10K.mbias.txt"), + path("$outputDir/methyldackel/mbias/SRR389222.mbias.txt"), + path("$outputDir/qualimap/Ecoli_10K/genome_results.txt"), + path("$outputDir/qualimap/SRR389222/genome_results.txt")).match("single_end_rrbs") }, + { assert new File("$outputDir/fastqc/Ecoli_10K_1_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/Ecoli_10K_2_fastqc.html").exists() }, + { assert new File("$outputDir/fastqc/SRR389222_fastqc.html").exists() }, + { assert new File("$outputDir/multiqc/bwameth/multiqc_report.html").exists() } ) } } diff --git a/tests/pipeline/bwameth/main.nf.test.snap b/tests/pipeline/bwameth/main.nf.test.snap index 0f3e3671..85e76f48 100644 --- a/tests/pipeline/bwameth/main.nf.test.snap +++ b/tests/pipeline/bwameth/main.nf.test.snap @@ -1,42 +1,72 @@ { "single_end_software_versions": { "content": [ - "{BWAMETH_ALIGN={bwameth=0.2.2}, BWAMETH_INDEX={bwameth=0.2.2}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, SAMPLESHEET_CHECK={python=3.8.3}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" + "{BWAMETH_ALIGN={bwameth=0.2.2}, BWAMETH_INDEX={bwameth=0.2.2}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, TRIMGALORE={cutadapt=3.4, trimgalore=0.6.7}, Workflow={nf-core/methylseq=2.5.0dev}}" ], - "timestamp": "2023-05-28T00:53:43+0000" + "timestamp": "2023-08-28T00:28:04+0000" }, "single_end_rrbs_software_versions": { "content": [ - "{BWAMETH_ALIGN={bwameth=0.2.2}, BWAMETH_INDEX={bwameth=0.2.2}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, SAMPLESHEET_CHECK={python=3.8.3}, Workflow={nf-core/methylseq=2.5.0dev}}" + "{BWAMETH_ALIGN={bwameth=0.2.2}, BWAMETH_INDEX={bwameth=0.2.2}, CAT_FASTQ={cat=8.30}, CUSTOM_DUMPSOFTWAREVERSIONS={python=3.11.0, yaml=6.0}, FASTQC={fastqc=0.11.9}, QUALIMAP_BAMQC={qualimap=2.2.2-dev}, Workflow={nf-core/methylseq=2.5.0dev}}" ], - "timestamp": "2023-05-28T00:53:43+0000" + "timestamp": "2023-08-28T00:28:04+0000" }, "single_end": { "content": [ - "Ecoli_10K_methylated.flagstat:md5,f520e87cc4050799a0dbed72909572ec", - "SRR389222_sub1.flagstat:md5,ad8159a7683b9c3057bf54ccb77a2ddc", - "SRR389222_sub2.flagstat:md5,2166a52f81f9b3881e8ac060876aa2d9", - "Ecoli_10K_methylated.markdup.sorted_CpG.bedGraph:md5,d3bce01078b6e7749f3906bf9faad5b5", - "SRR389222_sub1.markdup.sorted_CpG.bedGraph:md5,0944ad0e3b05791bf6dfd06be7ca4af1", - "SRR389222_sub2.markdup.sorted_CpG.bedGraph:md5,0a3c19af55d1625e91903ae25d1d2098", - "genome_results.txt:md5,1ee2e29ac41c2cd7e6a0f00741e8d16e", - "genome_results.txt:md5,2c755b15ae5ad4a1d29395320a6264ca", - "genome_results.txt:md5,3c7d14ea070df510941c55f72706a7a0" + "Ecoli_10K.flagstat:md5,f520e87cc4050799a0dbed72909572ec", + "Ecoli_10K.stats:md5,b744221f284d3b3f5afe0b4b2d1849d7", + "SRR389222.flagstat:md5,f5a2dd6c9532bbfb8fe78aad010d8737", + "SRR389222.stats:md5,cc81b8c56d038e437a99d9c04b61ce2d", + "Ecoli_10K.markdup.sorted.bam:md5,f582d626f4b78f4e9cc63ca6e20b42cd", + "Ecoli_10K.markdup.sorted.bam.bai:md5,faa46b80545d7eb45dfc659b46f419b0", + "SRR389222.markdup.sorted.bam:md5,46b5b49280efe5d5c5d1692092e8926f", + "SRR389222.markdup.sorted.bam.bai:md5,ad6cfa0344e1ba5b9057ea39f337b3d2", + [ + [ + "genome.fa:md5,923a0a268ad29fee3c3437d00f9970de", + "genome.fa.bwameth.c2t:md5,e51d48ed28fa0c26e2f9c9f13d09403b", + "genome.fa.bwameth.c2t.amb:md5,010a242c6764efb30141868a45d698b3", + "genome.fa.bwameth.c2t.ann:md5,09b4db3d87a2d4dac9e10e807f377110", + "genome.fa.bwameth.c2t.bwt:md5,4646f8ae6bd523b7f4106bbd32eff95e", + "genome.fa.bwameth.c2t.pac:md5,a662d7add09698e25c8152fd2306ec66", + "genome.fa.bwameth.c2t.sa:md5,4a1e905b828396a1909669bc9c573d8d" + ] + ], + "SRR389222.merged.fastq.gz:md5,ba5df0639e25988059a6f5bf309dbb6e", + "Ecoli_10K.markdup.sorted_CpG.bedGraph:md5,2fbe52f528b14b77380eceea8a621687", + "SRR389222.markdup.sorted_CpG.bedGraph:md5,febd0f93f46dfccabf69dbba3f518add", + "Ecoli_10K.mbias.txt:md5,3a448a2a6364b2de3129365a271c0534", + "SRR389222.mbias.txt:md5,fce04d733e066d0b933cedc602e2af81", + "genome_results.txt:md5,0f4749b54f9d923f0d4f20ad404b2062", + "genome_results.txt:md5,c786cc367645cee286360707e2624dca" ], - "timestamp": "2023-05-28T00:53:43+0000" + "timestamp": "2023-08-28T00:28:04+0000" }, "single_end_rrbs": { "content": [ - "Ecoli_10K_methylated.flagstat:md5,7c3bae0f9c700dde88785a7e94c6ae2c", - "SRR389222_sub1.flagstat:md5,897d500a710a56a7098172167fa71108", - "SRR389222_sub2.flagstat:md5,2d680c5657fc029b703b217be4af68e2", - "Ecoli_10K_methylated.sorted_CpG.bedGraph:md5,3656c54896013b76de978ab95c3f5975", - "SRR389222_sub1.sorted_CpG.bedGraph:md5,4475a9462ce86a019015b69b82a9d5a2", - "SRR389222_sub2.sorted_CpG.bedGraph:md5,18b8845d9d985d3c203ca6c9c40aab1b", - "genome_results.txt:md5,ca30867e16c5ca25c850c81d88563d41", - "genome_results.txt:md5,f01c68dd46ca9ec0af3d6ec926763b75", - "genome_results.txt:md5,f4513f5aa1622937ccdcfe92a6f877c0" + "Ecoli_10K.flagstat:md5,7c3bae0f9c700dde88785a7e94c6ae2c", + "Ecoli_10K.stats:md5,ff675c98abdae3c1bd83b26704d89e82", + "SRR389222.flagstat:md5,a90f1bdcb30f4d0597ccf69fe0b37b1f", + "SRR389222.stats:md5,b99800367e21a0c7c0d87e5fe29d9609", + [ + [ + "genome.fa:md5,923a0a268ad29fee3c3437d00f9970de", + "genome.fa.bwameth.c2t:md5,e51d48ed28fa0c26e2f9c9f13d09403b", + "genome.fa.bwameth.c2t.amb:md5,010a242c6764efb30141868a45d698b3", + "genome.fa.bwameth.c2t.ann:md5,09b4db3d87a2d4dac9e10e807f377110", + "genome.fa.bwameth.c2t.bwt:md5,4646f8ae6bd523b7f4106bbd32eff95e", + "genome.fa.bwameth.c2t.pac:md5,a662d7add09698e25c8152fd2306ec66", + "genome.fa.bwameth.c2t.sa:md5,4a1e905b828396a1909669bc9c573d8d" + ] + ], + "SRR389222.merged.fastq.gz:md5,ba5df0639e25988059a6f5bf309dbb6e", + "Ecoli_10K.sorted_CpG.bedGraph:md5,513797bcafa8724fc61484e2686af517", + "SRR389222.sorted_CpG.bedGraph:md5,a754358e8b95db30602aa29835a896bd", + "Ecoli_10K.mbias.txt:md5,ec13da6deba1ce147624bce065ec5df6", + "SRR389222.mbias.txt:md5,fce04d733e066d0b933cedc602e2af81", + "genome_results.txt:md5,e5e1ab8eb875aaf090b3a0d9b1927810", + "genome_results.txt:md5,199902f9d8f10f73bcb0a1ce29ceca5d" ], - "timestamp": "2023-05-28T00:53:43+0000" + "timestamp": "2023-08-28T00:28:04+0000" } } \ No newline at end of file diff --git a/workflows/methylseq.nf b/workflows/methylseq.nf index cf2bcca0..40b9ec60 100644 --- a/workflows/methylseq.nf +++ b/workflows/methylseq.nf @@ -4,7 +4,7 @@ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ -include { paramsSummaryLog; paramsSummaryMap } from 'plugin/nf-validation' +include { paramsSummaryLog; paramsSummaryMap; fromSamplesheet } from 'plugin/nf-validation' def logo = NfcoreTemplate.logo(workflow, params.monochrome_logs) def citation = '\n' + WorkflowMain.citation(workflow) + '\n' @@ -35,7 +35,6 @@ ch_multiqc_custom_methods_description = params.multiqc_methods_description ? fil // // SUBWORKFLOWS: Consisting of a mix of local and nf-core/modules // -include { INPUT_CHECK } from '../subworkflows/local/input_check' include { PREPARE_GENOME } from '../subworkflows/local/prepare_genome' // Aligner: bismark or bismark_hisat @@ -84,31 +83,34 @@ workflow METHYLSEQ { ch_versions = ch_versions.mix(PREPARE_GENOME.out.versions) // - // SUBWORKFLOW: Read in samplesheet, validate and stage input files + // Create input channel from input file provided through params.input // - INPUT_CHECK ( - file(params.input) - ) - .reads - .map { - meta, fastq -> + Channel + .fromSamplesheet("input") + .map { + meta, fastq_1, fastq_2 -> + if (!fastq_2) { + return [ meta + [ single_end:true ], [ fastq_1 ] ] + } else { + return [ meta + [ single_end:false ], [ fastq_1, fastq_2 ] ] + } + } + .groupTuple() + .map { + meta, fastq -> def meta_clone = meta.clone() meta_clone.id = meta_clone.id.split('_')[0..-2].join('_') [ meta_clone, fastq ] - } - .groupTuple(by: [0]) - .branch { - meta, fastq -> + } + .groupTuple(by: [0]) + .branch { + meta, fastq -> single: fastq.size() == 1 - return [ meta, fastq.flatten() ] + return [ meta, fastq.flatten() ] multiple: fastq.size() > 1 - return [ meta, fastq.flatten() ] - } - .set { ch_fastq } - ch_versions = ch_versions.mix(INPUT_CHECK.out.versions) - // TODO: OPTIONAL, you can use nf-validation plugin to create an input channel from the samplesheet with Channel.fromSamplesheet("input") - // See the documentation https://nextflow-io.github.io/nf-validation/samplesheets/fromSamplesheet/ - // ! There is currently no tooling to help you write a sample sheet schema + return [ meta, fastq.flatten() ] + } + .set { ch_fastq } // // MODULE: Concatenate FastQ files from same sample if required