mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-12-22 11:08:17 +00:00
Update docs
This commit is contained in:
parent
9cb958ca25
commit
d4b278eb65
1 changed files with 11 additions and 7 deletions
18
README.md
18
README.md
|
@ -226,12 +226,18 @@ We also use a standardised parameter called `params.publish_dir_mode` that can b
|
||||||
|
|
||||||
### CI tests
|
### CI tests
|
||||||
|
|
||||||
|
In order to test that each module added to `nf-core/modules` is actually working and to be able to track any changes to results files between module updates we have set-up a number of Github Actions CI tests to run each module on a minimal test dataset using Docker, Singularity and Conda.
|
||||||
|
|
||||||
|
#### Test data
|
||||||
|
|
||||||
- All test data for `nf-core/modules` MUST be added to [`tests/data/`](tests/data/) and organised by filename extension.
|
- All test data for `nf-core/modules` MUST be added to [`tests/data/`](tests/data/) and organised by filename extension.
|
||||||
|
|
||||||
- In order to keep the size of this repository as minimal as possible, pre-existing files from [`tests/data/`](tests/data/) MUST be reused if at all possible.
|
- In order to keep the size of this repository as minimal as possible, pre-existing files from [`tests/data/`](tests/data/) MUST be reused if at all possible.
|
||||||
|
|
||||||
- Test files MUST be kept as tiny as possible.
|
- Test files MUST be kept as tiny as possible.
|
||||||
|
|
||||||
|
#### Pytest workflow
|
||||||
|
|
||||||
- Every module MUST have a test workflow utilising test data added to the appropriate directory e.g. [`tests/software/fastqc/main.nf`](tests/software/fastqc/main.nf)
|
- Every module MUST have a test workflow utilising test data added to the appropriate directory e.g. [`tests/software/fastqc/main.nf`](tests/software/fastqc/main.nf)
|
||||||
|
|
||||||
- Any outputs produced by the test workflow MUST be included in the [pytest-workflow](https://pytest-workflow.readthedocs.io/en/stable) for that tool e.g. [`tests/software/fastqc/test.yml`](tests/software/fastqc/test.yml). `md5sum` checks are the preferable choice of test to determine file changes, however, this may not be possible for all outputs generated by some tools e.g. if they include time stamps or command-related headers. Please do your best to avoid just checking for the file being present e.g. it may still be possible to check that the file contains the appropriate text snippets.
|
- Any outputs produced by the test workflow MUST be included in the [pytest-workflow](https://pytest-workflow.readthedocs.io/en/stable) for that tool e.g. [`tests/software/fastqc/test.yml`](tests/software/fastqc/test.yml). `md5sum` checks are the preferable choice of test to determine file changes, however, this may not be possible for all outputs generated by some tools e.g. if they include time stamps or command-related headers. Please do your best to avoid just checking for the file being present e.g. it may still be possible to check that the file contains the appropriate text snippets.
|
||||||
|
@ -244,28 +250,28 @@ We also use a standardised parameter called `params.publish_dir_mode` that can b
|
||||||
|
|
||||||
2. Install any of [`Docker`](https://docs.docker.com/engine/installation/), [`Singularity`](https://www.sylabs.io/guides/3.0/user-guide/) or [`Conda`](https://conda.io/miniconda.html)
|
2. Install any of [`Docker`](https://docs.docker.com/engine/installation/), [`Singularity`](https://www.sylabs.io/guides/3.0/user-guide/) or [`Conda`](https://conda.io/miniconda.html)
|
||||||
|
|
||||||
3. Install [pytest-workflow](https://pytest-workflow.readthedocs.io/en/stable/#installation)
|
3. Install [`pytest-workflow`](https://pytest-workflow.readthedocs.io/en/stable/#installation)
|
||||||
|
|
||||||
4. Start running your own tests!
|
4. Start running your own tests!
|
||||||
|
|
||||||
- Typical command with Docker:
|
- Typical command with Docker:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
cd /<PATH>/<TO>/<GIT>/<CLONE>/<NF-CORE>/<MODULES>/
|
cd /path/to/git/clone/of/nf-core/modules/
|
||||||
PROFILE=docker pytest --tag tests/software/bowtie/build --symlink --wt 2 --keep-workflow-wd
|
PROFILE=docker pytest --tag tests/software/bowtie/build --symlink --wt 2 --keep-workflow-wd
|
||||||
```
|
```
|
||||||
|
|
||||||
- Typical command with Singularity:
|
- Typical command with Singularity:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
cd /<PATH>/<TO>/<GIT>/<CLONE>/<NF-CORE>/<MODULES>/
|
cd /path/to/git/clone/of/nf-core/modules/
|
||||||
TMPDIR=~ PROFILE=singularity pytest --tag tests/software/bowtie/build --symlink --wt 2 --keep-workflow-wd
|
TMPDIR=~ PROFILE=singularity pytest --tag tests/software/bowtie/build --symlink --wt 2 --keep-workflow-wd
|
||||||
```
|
```
|
||||||
|
|
||||||
- Typical command with Conda:
|
- Typical command with Conda:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
cd /<PATH>/<TO>/<GIT>/<CLONE>/<NF-CORE>/<MODULES>/
|
cd /path/to/git/clone/of/nf-core/modules/
|
||||||
PROFILE=conda pytest --tag tests/software/bowtie/build --symlink --wt 2 --keep-workflow-wd
|
PROFILE=conda pytest --tag tests/software/bowtie/build --symlink --wt 2 --keep-workflow-wd
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -275,7 +281,7 @@ We also use a standardised parameter called `params.publish_dir_mode` that can b
|
||||||
|
|
||||||
### Uploading to `nf-core/modules`
|
### Uploading to `nf-core/modules`
|
||||||
|
|
||||||
[Fork](https://help.github.com/articles/fork-a-repo/) the `nf-core/modules` repository to your own GitHub account. Within the local clone of your fork add the module file to the [`software/`](software) directory.
|
[Fork](https://help.github.com/articles/fork-a-repo/) the `nf-core/modules` repository to your own GitHub account. Within the local clone of your fork add the module file to the [`software/`](software) directory. Please try and keep PRs as atomic as possible to aid the reviewing process - ideally, one module addition/update per PR.
|
||||||
|
|
||||||
Commit and push these changes to your local clone on GitHub, and then [create a pull request](https://help.github.com/articles/creating-a-pull-request-from-a-fork/) on the `nf-core/modules` GitHub repo with the appropriate information.
|
Commit and push these changes to your local clone on GitHub, and then [create a pull request](https://help.github.com/articles/creating-a-pull-request-from-a-fork/) on the `nf-core/modules` GitHub repo with the appropriate information.
|
||||||
|
|
||||||
|
@ -304,8 +310,6 @@ If you use the module files in this repository for your analysis please you can
|
||||||
> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.
|
> Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.
|
||||||
>
|
>
|
||||||
> _Nat Biotechnol._ 2020 Feb 13. doi: [10.1038/s41587-020-0439-x](https://dx.doi.org/10.1038/s41587-020-0439-x).
|
> _Nat Biotechnol._ 2020 Feb 13. doi: [10.1038/s41587-020-0439-x](https://dx.doi.org/10.1038/s41587-020-0439-x).
|
||||||
> ReadCube: [Full Access Link](https://rdcu.be/b1GjZ)
|
|
||||||
|
|
||||||
|
|
||||||
<!---
|
<!---
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue