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

Added nf-test for pairtools/parse #6264

Merged
merged 3 commits into from
Aug 24, 2024
Merged
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
40 changes: 40 additions & 0 deletions modules/nf-core/pairtools/parse/tests/main.nf.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@

nextflow_process {

name "Test Process PAIRTOOLS_PARSE"
script "../main.nf"
process "PAIRTOOLS_PARSE"
config "./nextflow.config"

tag "modules"
tag "modules_nfcore"
tag "pairtools"
tag "pairtools/parse"

test("test-pairtools-parse") {

when {
process {
"""
input[0] = [ [ id:'test', single_end:false ], // meta map
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pairtools/mock.sam', checkIfExists: true) ]
input[1] = file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pairtools/mock.chrom.sizes', checkIfExists: true)

"""
}
}

then {
assertAll(
{ assert process.success },
{ assert snapshot(
path(process.out.pairsam[0][1]).linesGzip[3..7],
process.out.stat,
process.out.versions
).match()
}
)
}
}

}
30 changes: 30 additions & 0 deletions modules/nf-core/pairtools/parse/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"test-pairtools-parse": {
"content": [
[
"#chromsize: chr1 1000",
"#chromsize: chr2 1000",
"#samheader: @SQ\tSN:chr1\tLN:1000",
"#samheader: @SQ\tSN:chr2\tLN:1000",
"#samheader: @PG\tID:mock\tPN:mock\tVN:0.0.0\tCL:mock"
],
[
[
{
"id": "test",
"single_end": false
},
"test.raw.pairsam.stat:md5,054bf78ee4f0a4c447ad3eeb81f1f4ae"
]
],
[
"versions.yml:md5,2c8cb00722749f8e3831464a5057c519"
]
],
"meta": {
"nf-test": "0.8.4",
"nextflow": "24.04.4"
},
"timestamp": "2024-08-23T11:17:35.185642"
}
}
5 changes: 5 additions & 0 deletions modules/nf-core/pairtools/parse/tests/nextflow.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
process {
withName: PAIRTOOLS_PARSE {
ext.prefix = { "${meta.id}.raw" }
}
}
3 changes: 0 additions & 3 deletions tests/config/pytest_modules.yml
Original file line number Diff line number Diff line change
Expand Up @@ -983,9 +983,6 @@ oncocnv:
paftools/sam2paf:
- modules/nf-core/paftools/sam2paf/**
- test/modules/nf-core/paftools/sam2paf/**
pairtools/parse:
- modules/nf-core/pairtools/parse/**
- tests/modules/nf-core/pairtools/parse/**
pairtools/restrict:
- modules/nf-core/pairtools/restrict/**
- tests/modules/nf-core/pairtools/restrict/**
Expand Down
14 changes: 0 additions & 14 deletions tests/modules/nf-core/pairtools/parse/main.nf

This file was deleted.

9 changes: 0 additions & 9 deletions tests/modules/nf-core/pairtools/parse/nextflow.config

This file was deleted.

17 changes: 0 additions & 17 deletions tests/modules/nf-core/pairtools/parse/test.yml

This file was deleted.

Loading