Skip to content

Commit e5c8c9d

Browse files
committed
update featurecounts_group_type tests
1 parent 2ce830b commit e5c8c9d

File tree

2 files changed

+164
-268
lines changed

2 files changed

+164
-268
lines changed

tests/featurecounts_group_type.nf.test

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,11 @@ nextflow_pipeline {
1414

1515
then {
1616
// stable_name: All files + folders in ${params.outdir}/ with a stable name
17-
def stable_name = getAllFilesFromDir(params.outdir, true, ['pipeline_info/*.{html,json,txt}'], null)
17+
def stable_name = getAllFilesFromDir(params.outdir, relative: true, includeDir: true, ignore: ['pipeline_info/*.{html,json,txt}'])
1818
// stable_path: All files in ${params.outdir}/ with stable content
19-
def stable_path = getAllFilesFromDir(params.outdir, false, null, 'tests/.nftignore')
19+
def stable_path = getAllFilesFromDir(params.outdir, ignoreFile: 'tests/.nftignore')
20+
// bam_files: All bam files
21+
def bam_files = getAllFilesFromDir(params.outdir, include: ['**/*.bam'])
2022
assertAll(
2123
{ assert workflow.success},
2224
{ assert snapshot(
@@ -25,9 +27,11 @@ nextflow_pipeline {
2527
// pipeline versions.yml file for multiqc from which Nextflow version is removed because we tests pipelines on multiple Nextflow versions
2628
removeNextflowVersion("$outputDir/pipeline_info/nf_core_rnaseq_software_mqc_versions.yml"),
2729
// All stable path name, with a relative path
28-
getRelativePath(stable_name, outputDir),
30+
stable_name,
2931
// All files with stable contents
30-
stable_path
32+
stable_path,
33+
// All bam files
34+
bam_files.collect{ file -> [ file.getName(), bam(file.toString()).getReadsMD5() ] }
3135
).match() }
3236
)
3337
}
@@ -46,9 +50,9 @@ nextflow_pipeline {
4650

4751
then {
4852
// stable_name: All files + folders in ${params.outdir}/ with a stable name
49-
def stable_name = getAllFilesFromDir(params.outdir, true, ['pipeline_info/*.{html,json,txt}'], null)
53+
def stable_name = getAllFilesFromDir(params.outdir, relative: true, includeDir: true, ignore: ['pipeline_info/*.{html,json,txt}'])
5054
// stable_path: All files in ${params.outdir}/ with stable content
51-
def stable_path = getAllFilesFromDir(params.outdir, false, null, 'tests/.nftignore')
55+
def stable_path = getAllFilesFromDir(params.outdir, ignoreFile: 'tests/.nftignore')
5256
assertAll(
5357
{ assert workflow.success},
5458
{ assert snapshot(
@@ -57,7 +61,7 @@ nextflow_pipeline {
5761
// pipeline versions.yml file for multiqc from which Nextflow version is removed because we tests pipelines on multiple Nextflow versions
5862
removeNextflowVersion("$outputDir/pipeline_info/nf_core_rnaseq_software_mqc_versions.yml"),
5963
// All stable path name, with a relative path
60-
getRelativePath(stable_name, outputDir),
64+
stable_name,
6165
// All files with stable contents
6266
stable_path
6367
).match() }

0 commit comments

Comments
 (0)