-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
return the test, but remove section not used
- Loading branch information
1 parent
261f455
commit 09ea6f0
Showing
1 changed file
with
57 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
nextflow_pipeline { | ||
|
||
name "Test fetching small datasets from NCBI" | ||
script "main.nf" | ||
|
||
test("basic integration test") { | ||
|
||
when { | ||
params { | ||
input = "$baseDir/tests/data/samplesheet.csv" | ||
outdir = "test1_out" | ||
} | ||
} | ||
|
||
then { | ||
assert workflow.success | ||
|
||
// IRIDA Next output file | ||
assert path("$launchDir/test1_out/iridanext.output.json").json == path("$baseDir/tests/data/test1_iridanext.output.json").json | ||
|
||
// Output data | ||
assert path("$launchDir/test1_out/reads/ERR1109373_1.fastq.gz").linesGzip.size() == 512 | ||
assert path("$launchDir/test1_out/reads/ERR1109373_2.fastq.gz").linesGzip.size() == 512 | ||
assert path("$launchDir/test1_out/reads/SRR13191702_1.fastq.gz").linesGzip.size() == 364 | ||
assert path("$launchDir/test1_out/reads/SRR13191702_2.fastq.gz").linesGzip.size() == 364 | ||
} | ||
} | ||
|
||
test("integration test with prefetch failures") { | ||
|
||
when { | ||
params { | ||
input = "$baseDir/tests/data/errorsheet.csv" | ||
outdir = "results" | ||
} | ||
} | ||
|
||
then { | ||
assert workflow.success | ||
|
||
// IRIDA Next output file | ||
assert path("$launchDir/results/iridanext.output.json").json == path("$baseDir/tests/data/prefetch_errors_iridanext.output.json").json | ||
|
||
// Output data: | ||
assert path("$launchDir/results/reads/ERR1109373_1.fastq.gz").linesGzip.size() == 512 | ||
assert path("$launchDir/results/reads/ERR1109373_2.fastq.gz").linesGzip.size() == 512 | ||
assert path("$launchDir/results/reads/SRR13191702_1.fastq.gz").linesGzip.size() == 364 | ||
assert path("$launchDir/results/reads/SRR13191702_2.fastq.gz").linesGzip.size() == 364 | ||
|
||
// These files should have failed, and have no output reads: | ||
assert path("$launchDir/results/reads/SRR999908_1.fastq.gz").exists() == false | ||
assert path("$launchDir/results/reads/SRR999908_2.fastq.gz").exists() == false | ||
assert path("$launchDir/results/reads/SRR999934_1.fastq.gz").exists() == false | ||
assert path("$launchDir/results/reads/SRR999934_2.fastq.gz").exists() == false | ||
} | ||
} | ||
} |