From 60bc080178fbaf25e0c9044638c0e198c9b55336 Mon Sep 17 00:00:00 2001 From: Marcel Ribeiro-Dantas Date: Tue, 26 Mar 2024 13:08:38 -0300 Subject: [PATCH] Finish conversion to Markdown:wq --- src/content/blog/2024/nf-test-in-nf-core.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/content/blog/2024/nf-test-in-nf-core.md b/src/content/blog/2024/nf-test-in-nf-core.md index 11a4d7a3..9231efb5 100644 --- a/src/content/blog/2024/nf-test-in-nf-core.md +++ b/src/content/blog/2024/nf-test-in-nf-core.md @@ -63,12 +63,12 @@ Following these insights, fetchngs has been at the forefront of incorporating nf # Pipeline development with nf-test -For newer nf-core pipelines, integrating nf-test as early as possible in the development process is highly recommended. An example of a pipeline that has benefitted from the incorporation of nf-tests throughout its development is phageannotator. Although integrating nf-test during pipeline development has presented challenges, it has offered a unique opportunity to evaluate different testing methodologies and has been instrumental in identifying numerous development errors that might have been overlooked using the previous test profiles approach. Additionally, investing time early on has significantly simplified modifying different aspects of the pipeline, ensuring that functionality and output remain unaffected. +**For newer nf-core pipelines, integrating nf-test as early as possible in the development process is highly recommended**. An example of a pipeline that has benefitted from the incorporation of nf-tests throughout its development is [phageannotator](https://github.com/nf-core/phageannotator). Although integrating nf-test during pipeline development has presented challenges, it has offered a unique opportunity to evaluate different testing methodologies and has been instrumental in identifying numerous development errors that might have been overlooked using the previous test profiles approach. Additionally, investing time early on has significantly simplified modifying different aspects of the pipeline, ensuring that functionality and output remain unaffected. For those embarking on creating new Nextflow pipelines, here are a few key takeaways from our experience: -1. Leverage nf-core modules/subworkflows extensively. Devoting time early to contributing modules/subworkflows to nf-core not only streamlines future development for you and your PR reviewers but also simplifies maintaining, linting, and updating pipeline components through nf-core tools. Furthermore, these modules will likely benefit others in the community with similar research interests. -2. Prioritize incremental changes over large overhauls. Incremental changes are almost always preferable to large, unwieldy modifications. This approach is particularly beneficial when monitoring and updating nf-tests at the module, subworkflow, workflow, and pipeline levels. Introducing too many changes simultaneously can overwhelm both developers and reviewers, making it challenging to track what has been modified and what requires testing. Aim to keep changes straightforward and manageable. -3. Facilitate parallel execution of nf-test to generate and test snapshots. By default, nf-test runs each test sequentially, which can make the process of running multiple tests to generate or update snapshots time-consuming. Implementing scripts that enable tests to run in parallel—whether through a workload manager or in the cloud—can save a considerable amount of time and simplify the monitoring of passing and failing tests. +1. **Leverage nf-core modules/subworkflows extensively**. Devoting time early to contributing modules/subworkflows to nf-core not only streamlines future development for you and your PR reviewers but also simplifies maintaining, linting, and updating pipeline components through nf-core tools. Furthermore, these modules will likely benefit others in the community with similar research interests. +2. **Prioritize incremental changes over large overhauls**. Incremental changes are almost always preferable to large, unwieldy modifications. This approach is particularly beneficial when monitoring and updating nf-tests at the module, subworkflow, workflow, and pipeline levels. Introducing too many changes simultaneously can overwhelm both developers and reviewers, making it challenging to track what has been modified and what requires testing. Aim to keep changes straightforward and manageable. +3. **Facilitate parallel execution of nf-test to generate and test snapshots**. By default, nf-test runs each test sequentially, which can make the process of running multiple tests to generate or update snapshots time-consuming. Implementing scripts that enable tests to run in parallel—whether through a workload manager or in the cloud—can save a considerable amount of time and simplify the monitoring of passing and failing tests. # Community and contribution @@ -77,7 +77,7 @@ nf-core is a community that relies on consistent contributions, evaluation, and 1. **Adding nf-tests to new and existing nf-core module/subworkflows**. There has been a recent emphasis on migrating modules/subworkflows from pytest to nf-test because of the advantages mentioned previously. Fortunately, the nf-core team has added very helpful [instructions](https://nf-co.re/docs/contributing/modules#migrating-from-pytest-to-nf-test) to the website, which has made this process much more streamlined. 2. **Adding nf-tests to nf-core pipelines**. Another area of focus is the addition of nf-tests to nf-core pipelines. This process can be quite difficult for large, complex pipelines, but there are now several examples of pipelines with nf-tests that can be used as a blueprint for getting started ([fetchngs](https://github.com/nf-core/fetchngs/tree/master), [sarek](https://github.com/nf-core/sarek/tree/master), [readsimulator](https://github.com/nf-core/readsimulator/tree/master), [phageannotator](https://github.com/nf-core/phageannotator)). -> These are great areas to work on & contribute in the upcoming nf-core hackathon in March 2024 +> These are great areas to work on & contribute in the upcoming nf-core [hackathon in March 2024](https://nf-co.re/events/2024/hackathon-march-2024) Yet the role of the community is not limited to adding test code. A robust testing infrastructure requires nf-core users to identify testing errors, and additional test cases, and provide feedback so that the system can continually be improved. Each of us brings a different perspective, and the development-feedback loop that results from collaboration brings about much a more effective, transparent, and inclusive system than if we worked in isolation.