-
Notifications
You must be signed in to change notification settings - Fork 38
Description
If an nf-test includes paths to scripts (for example, in a run() function in the setup block), it checks for the script file's existence and prints a warning if it cannot be found.
This is usually good behaviour, but we are using the nft-utils nf-core depencency management functionality to install various dependencies in the setup block just before a test runs. In these cases, we get a warning that the script doesn't exist even if the script will be downloaded, across all .nf.test files in a project even if they are not being run.
Warning: Module /home/runner/work/nf-core-modules/nf-core-modules/subworkflows/sanger-tol/fasta_bam_scaffolding_yahs/tests/main.nf.test: Dependency '/home/runner/work/nf-core-modules/nf-core-modules/subworkflows/sanger-tol/fasta_bam_scaffolding_yahs/tests/../../../../modules/nf-core/samtools/view/main.nf' not found.
Instead, this dependency check and warning could be printed out only when or if e.g. the run() function is actually executed - this would mean that these warnings would only be printed if the test is being run, and after any missing dependencies have been installed.