Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ampliseq samplesheet creation dependent on #790 in ampliseq #324

Draft
wants to merge 3 commits into
base: dev
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions modules/local/sra_to_samplesheet/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ process SRA_TO_SAMPLESHEET {
pipeline_map << [ replicate: 1 ]
} else if (pipeline == 'taxprofiler') {
pipeline_map << [ fasta: '' ]
} else if (pipeline == 'ampliseq'){
pipeline_map << [ run: '']
}
}
pipeline_map << meta_clone
Expand Down
2 changes: 1 addition & 1 deletion nextflow_schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"type": "string",
"fa_icon": "fab fa-apple",
"description": "Name of supported nf-core pipeline e.g. 'rnaseq'. A samplesheet for direct use with the pipeline will be created with the appropriate columns.",
"enum": ["rnaseq", "atacseq", "viralrecon", "taxprofiler"]
"enum": ["rnaseq", "atacseq", "viralrecon", "taxprofiler", "ampliseq"]
},
"nf_core_rnaseq_strandedness": {
"type": "string",
Expand Down
55 changes: 55 additions & 0 deletions workflows/sra/tests/sra_nf_core_pipeline_ampliseq.nf.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
nextflow_workflow {

name "Test workflow: sra/main.nf"
script "../main.nf"
workflow "SRA"
tag "SRA_NF_CORE_PIPELINE_AMPLISEQ"

// Dependencies
tag "SRA_IDS_TO_RUNINFO"
tag "SRA_RUNINFO_TO_FTP"
tag "SRA_FASTQ_FTP"
tag "SRA_TO_SAMPLESHEET"
tag "MULTIQC_MAPPINGS_CONFIG"

test("Parameters: --nf_core_pipeline ampliseq") {

when {
workflow {
"""
input[0] = Channel.from("DRX026011", "ERX1234253", "SRX6725035")
"""
}
params {
nf_core_pipeline = "ampliseq"
}
}

then {
assert workflow.success

assertAll(
{
with(workflow.out.samplesheet) {
assert path(get(0)).readLines().size() == 4
assert path(get(0)).readLines()*.split(',')[0].take(4) == ['"sample', '"fastq_1"', '"fastq_2"', '"run"']
assert path(get(0)).readLines()*.split(',').collect { it[0] } == ['"sample"', '"DRX026011"', '"ERX1234253"', '"SRX6725035"']
assert path(get(0)).text.contains('Illumina HiSeq 2500')
}
},
{
with(workflow.out.mappings) {
assert path(get(0)).readLines().size() == 4
assert path(get(0)).readLines()*.split(',').collect { it[0] } == ['"sample"', '"DRX026011"', '"ERX1234253"', '"SRX6725035"']
assert path(get(0)).text.contains('Illumina HiSeq 2500')
}
},
{
with(workflow.out.sample_mappings) {
assert path(get(0)[0]).md5 == "1ac06bb95b503703430e74660bbdd768"
}
}
)
}
}
}
Loading