forked from nf-core/modules
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
6201 feature add stub in picardcreatesequencedictionary (nf-core#6205)
* migrate-pytest * updated snapshots * Update modules/nf-core/picard/createsequencedictionary/tests/main.nf.test Co-authored-by: Maxime U Garcia <[email protected]> * recreate snaps * Update modules/nf-core/picard/createsequencedictionary/main.nf --------- Co-authored-by: Maxime U Garcia <[email protected]>
- Loading branch information
1 parent
29d01cb
commit 759232f
Showing
7 changed files
with
121 additions
and
32 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
61 changes: 61 additions & 0 deletions
61
modules/nf-core/picard/createsequencedictionary/tests/main.nf.test
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,61 @@ | ||
nextflow_process { | ||
|
||
name "Test Process PICARD_CREATESEQUENCEDICTIONARY" | ||
script "../main.nf" | ||
process "PICARD_CREATESEQUENCEDICTIONARY" | ||
|
||
tag "modules" | ||
tag "modules_nfcore" | ||
tag "picard" | ||
tag "picard/createsequencedictionary" | ||
|
||
test("sarscov2 - fasta") { | ||
|
||
when { | ||
process { | ||
""" | ||
input[0] = [ | ||
[ id:'test' ], // meta map | ||
file(params.modules_testdata_base_path + 'genomics/sarscov2/genome/genome.fasta', checkIfExists: true)] | ||
""" | ||
} | ||
} | ||
|
||
then { | ||
assertAll( | ||
{ assert process.success }, | ||
{ assert snapshot( | ||
file(process.out.reference_dict[0][1]).name, | ||
process.out.versions | ||
).match() | ||
} | ||
|
||
) | ||
} | ||
|
||
} | ||
|
||
test("sarscov2 - fasta - stub") { | ||
|
||
options "-stub" | ||
|
||
when { | ||
process { | ||
""" | ||
input[0] = [ | ||
[ id:'test' ], // meta map | ||
file(params.modules_testdata_base_path + 'genomics/sarscov2/genome/genome.fasta', checkIfExists: true)] | ||
""" | ||
} | ||
} | ||
|
||
then { | ||
assertAll( | ||
{ assert process.success }, | ||
{ assert snapshot(process.out).match() } | ||
) | ||
} | ||
|
||
} | ||
|
||
} |
48 changes: 48 additions & 0 deletions
48
modules/nf-core/picard/createsequencedictionary/tests/main.nf.test.snap
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,48 @@ | ||
{ | ||
"sarscov2 - fasta - stub": { | ||
"content": [ | ||
{ | ||
"0": [ | ||
[ | ||
{ | ||
"id": "test" | ||
}, | ||
"test.dict:md5,d41d8cd98f00b204e9800998ecf8427e" | ||
] | ||
], | ||
"1": [ | ||
"versions.yml:md5,fdb110d8c303ffa0615bb200f9a2c999" | ||
], | ||
"reference_dict": [ | ||
[ | ||
{ | ||
"id": "test" | ||
}, | ||
"test.dict:md5,d41d8cd98f00b204e9800998ecf8427e" | ||
] | ||
], | ||
"versions": [ | ||
"versions.yml:md5,fdb110d8c303ffa0615bb200f9a2c999" | ||
] | ||
} | ||
], | ||
"meta": { | ||
"nf-test": "0.9.0", | ||
"nextflow": "24.04.4" | ||
}, | ||
"timestamp": "2024-08-19T07:02:59.686224426" | ||
}, | ||
"sarscov2 - fasta": { | ||
"content": [ | ||
"test.dict", | ||
[ | ||
"versions.yml:md5,fdb110d8c303ffa0615bb200f9a2c999" | ||
] | ||
], | ||
"meta": { | ||
"nf-test": "0.9.0", | ||
"nextflow": "24.04.4" | ||
}, | ||
"timestamp": "2024-08-16T14:31:34.330709472" | ||
} | ||
} |
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
15 changes: 0 additions & 15 deletions
15
tests/modules/nf-core/picard/createsequencedictionary/main.nf
This file was deleted.
Oops, something went wrong.
5 changes: 0 additions & 5 deletions
5
tests/modules/nf-core/picard/createsequencedictionary/nextflow.config
This file was deleted.
Oops, something went wrong.
9 changes: 0 additions & 9 deletions
9
tests/modules/nf-core/picard/createsequencedictionary/test.yml
This file was deleted.
Oops, something went wrong.