Skip to content

Commit

Permalink
Switch to nf-bam plugin for output validation.
Browse files Browse the repository at this point in the history
  • Loading branch information
MatthiasZepper committed Nov 25, 2024
1 parent ad3f4e7 commit ff07ff9
Show file tree
Hide file tree
Showing 8 changed files with 37 additions and 67 deletions.
8 changes: 2 additions & 6 deletions modules/nf-core/umicollapse/tests/main.nf.test
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,6 @@ nextflow_process {
tag "modules"
tag "modules_nfcore"
tag "umicollapse"
tag "umitools/extract"
tag "samtools/index"
tag "bwa/index"
tag "bwa/mem"

test("umicollapse single end test") {

Expand All @@ -32,7 +28,7 @@ nextflow_process {
assertAll(
{ assert process.success },
{ assert snapshot(
process.out.bam,
bam(process.out.bam[0][1]).getSamLinesMD5(),
process.out.versions).match() }
)
}
Expand All @@ -59,7 +55,7 @@ nextflow_process {
assertAll(
{ assert process.success },
{ assert snapshot(
process.out.bam,
bam(process.out.bam[0][1]).getSamLinesMD5(),
process.out.versions).match() }
)
}
Expand Down
23 changes: 4 additions & 19 deletions modules/nf-core/umicollapse/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
@@ -1,15 +1,7 @@
{
"umicollapse single end test": {
"content": [
[
[
{
"id": "test",
"single_end": true
},
"test.dedup.bam:md5,77e83b5d15bb188de1149bf49c4c7b51"
]
],
"9158ea6e7a0e54819e25cbac5fbc5cc0",
[
"versions.yml:md5,03fdbcb1ba9bd40325ca42859d39deb1"
]
Expand All @@ -18,18 +10,11 @@
"nf-test": "0.8.4",
"nextflow": "24.10.1"
},
"timestamp": "2024-11-24T13:57:11.593685"
"timestamp": "2024-11-25T17:31:45.024306"
},
"umicollapse paired tests": {
"content": [
[
[
{
"id": "test"
},
"test.dedup.bam:md5,09cfdd25a90ae5bd7c78912984feadbe"
]
],
"b7be15ac7aae194b04bdbb56f3534495",
[
"versions.yml:md5,03fdbcb1ba9bd40325ca42859d39deb1"
]
Expand All @@ -38,7 +23,7 @@
"nf-test": "0.8.4",
"nextflow": "24.10.1"
},
"timestamp": "2024-11-24T13:57:20.582394"
"timestamp": "2024-11-25T17:31:52.072799"
},
"umicollapse fastq test (paired-end)": {
"content": [
Expand Down
4 changes: 2 additions & 2 deletions modules/nf-core/umitools/dedup/tests/main.nf.test
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ nextflow_process {
{ assert process.success },
{ assert path("${process.out.log[0][1]}").exists() },
{ assert snapshot(
process.out.bam,
bam(process.out.bam[0][1]).getSamLinesMD5(),
process.out.versions).match() }
)
}
Expand Down Expand Up @@ -90,7 +90,7 @@ nextflow_process {
{ assert process.success },
{ assert path("${process.out.log[0][1]}").exists() },
{ assert snapshot(
process.out.bam,
bam(process.out.bam[0][1]).getSamLinesMD5(),
process.out.tsv_edit_distance,
process.out.tsv_per_umi,
process.out.tsv_umi_per_position,
Expand Down
24 changes: 4 additions & 20 deletions modules/nf-core/umitools/dedup/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
Expand Up @@ -37,15 +37,7 @@
},
"pe - with stats": {
"content": [
[
[
{
"id": "test",
"single_end": false
},
"test.dedup.bam:md5,3c44698572f108dd5a9bd205375be2b8"
]
],
"b7be15ac7aae194b04bdbb56f3534495",
[
[
{
Expand Down Expand Up @@ -81,7 +73,7 @@
"nf-test": "0.8.4",
"nextflow": "24.10.1"
},
"timestamp": "2024-11-23T09:08:10.434136"
"timestamp": "2024-11-25T17:25:28.939957"
},
"se - no stats - stub": {
"content": [
Expand Down Expand Up @@ -116,15 +108,7 @@
},
"pe - no stats": {
"content": [
[
[
{
"id": "test",
"single_end": false
},
"test.dedup.bam:md5,3c44698572f108dd5a9bd205375be2b8"
]
],
"b7be15ac7aae194b04bdbb56f3534495",
[
"versions.yml:md5,e2f5146464c09bf7ae98c85ea5410e50"
]
Expand All @@ -133,6 +117,6 @@
"nf-test": "0.8.4",
"nextflow": "24.10.1"
},
"timestamp": "2024-11-23T09:07:32.367542"
"timestamp": "2024-11-25T17:24:51.423637"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,8 @@ nextflow_workflow {
then {
assertAll(
{ assert workflow.success},
{ assert snapshot(workflow.out.bam, workflow.out.versions).match() },
{ assert snapshot(bam(workflow.out.bam[0][1]).getSamLinesMD5()).match("test_bam_dedup_stats_samtools_umicollapse_bam")}, // separate, because of linting error otherwise
{ assert snapshot(workflow.out.versions).match("test_bam_dedup_stats_samtools_umicollapse_versions") },
{ assert workflow.out.bam.get(0).get(1) ==~ ".*.bam"},
{ assert workflow.out.bai.get(0).get(1) ==~ ".*.bai"},
{ assert workflow.out.dedup_stats.get(0).get(1) ==~ ".*_UMICollapse.log"},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,46 +16,38 @@
},
"timestamp": "2024-11-24T13:57:02.323104"
},
"test_bam_dedup_stats_samtools_umicollapse_flagstats": {
"test_bam_dedup_stats_samtools_umicollapse_versions": {
"content": [
[
[
{
"id": "test"
},
"test.flagstat:md5,18d602435a02a4d721b78d1812622159"
]
"versions.yml:md5,20605eb79c410c0ed179ba660d82f75b",
"versions.yml:md5,23617661d2c899996bee2b05db027e25",
"versions.yml:md5,657bce03545b4c57f9c5fc4314bf85f7",
"versions.yml:md5,e02a62a393a833778e16542eeed0d148",
"versions.yml:md5,ef00762e264b99ac45713dc0dedf4060"
]
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "24.10.1"
},
"timestamp": "2024-11-24T13:57:02.366866"
"timestamp": "2024-11-25T18:39:15.637444"
},
"sarscov2_bam_bai": {
"test_bam_dedup_stats_samtools_umicollapse_flagstats": {
"content": [
[
[
{
"id": "test"
},
"test.dedup.bam:md5,09cfdd25a90ae5bd7c78912984feadbe"
"test.flagstat:md5,18d602435a02a4d721b78d1812622159"
]
],
[
"versions.yml:md5,20605eb79c410c0ed179ba660d82f75b",
"versions.yml:md5,23617661d2c899996bee2b05db027e25",
"versions.yml:md5,657bce03545b4c57f9c5fc4314bf85f7",
"versions.yml:md5,e02a62a393a833778e16542eeed0d148",
"versions.yml:md5,ef00762e264b99ac45713dc0dedf4060"
]
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "24.10.1"
},
"timestamp": "2024-11-24T13:57:02.27027"
"timestamp": "2024-11-24T13:57:02.366866"
},
"test_bam_dedup_stats_samtools_umicollapse_idxstats": {
"content": [
Expand All @@ -73,5 +65,15 @@
"nextflow": "24.10.1"
},
"timestamp": "2024-11-24T13:57:02.410712"
},
"test_bam_dedup_stats_samtools_umicollapse_bam": {
"content": [
"b7be15ac7aae194b04bdbb56f3534495"
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "24.10.1"
},
"timestamp": "2024-11-25T18:39:15.613319"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ nextflow_workflow {
{ assert workflow.out.bam.get(0).get(1) ==~ ".*.bam"},
{ assert workflow.out.bai.get(0).get(1) ==~ ".*.bai"},
{ assert snapshot(
bam(workflow.out.bam[0][1]).getSamLinesMD5(),
workflow.out.stats,
workflow.out.flagstat,
workflow.out.idxstats,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"sarscov2_bam_bai": {
"content": [
"b7be15ac7aae194b04bdbb56f3534495",
[
[
{
Expand Down Expand Up @@ -37,7 +38,7 @@
"nf-test": "0.8.4",
"nextflow": "24.10.1"
},
"timestamp": "2024-11-23T09:16:50.849764"
"timestamp": "2024-11-25T17:23:13.841219"
},
"sarscov2_bam_bai - stub": {
"content": [
Expand Down

0 comments on commit ff07ff9

Please sign in to comment.