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

Add nf-test to porechop_abi #6049

Merged

Conversation

LilyAnderssonLee
Copy link
Contributor

PR checklist

Will be used in nf-core/taxprofiler#145

  • This comment contains a description of changes (with reason).
  • If you've fixed a bug or added code that should be tested, add tests!
  • If you've added a new tool - have you followed the module conventions in the contribution docs
  • If necessary, include test data in your PR.
  • Remove all TODO statements.
  • Emit the versions.yml file.
  • Follow the naming conventions.
  • Follow the parameters requirements.
  • Follow the input/output options guidelines.
  • Add a resource label
  • Use BioConda and BioContainers if possible to fulfil software requirements.
  • Ensure that the test works with either Docker / Singularity. Conda CI tests can be quite flaky:
    • For modules:
      • nf-core modules test <MODULE> --profile docker
      • nf-core modules test <MODULE> --profile singularity
      • nf-core modules test <MODULE> --profile conda
    • For subworkflows:
      • nf-core subworkflows test <SUBWORKFLOW> --profile docker
      • nf-core subworkflows test <SUBWORKFLOW> --profile singularity
      • nf-core subworkflows test <SUBWORKFLOW> --profile conda

Copy link
Contributor

@SPPearce SPPearce left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also please add the check that the input/output files do not match.

modules/nf-core/porechop/abi/main.nf Outdated Show resolved Hide resolved
modules/nf-core/porechop/abi/main.nf Outdated Show resolved Hide resolved
modules/nf-core/porechop/abi/main.nf Outdated Show resolved Hide resolved
modules/nf-core/porechop/abi/meta.yml Outdated Show resolved Hide resolved
@SPPearce
Copy link
Contributor

Don't forget to the remove the pytest files too (including from the config).

@LilyAnderssonLee
Copy link
Contributor Author

Don't forget to the remove the pytest files too (including from the config).

Do I need to include config to the test? Do you have an example of this?

@SPPearce
Copy link
Contributor

Don't forget to the remove the pytest files too (including from the config).

Do I need to include config to the test? Do you have an example of this?

Sorry, I mean you need to remove them from:
https://github.com/nf-core/modules/blob/master/tests/config/pytest_modules.yml
to stop the pytest tests from being ran.

@LilyAnderssonLee LilyAnderssonLee requested a review from a team as a code owner July 29, 2024 09:39
@LilyAnderssonLee LilyAnderssonLee requested review from LeuThrAsp and removed request for a team July 29, 2024 09:39
@LilyAnderssonLee
Copy link
Contributor Author

The process tests passed, but the stability check still fails. It seems that redirecting the log file is not correct, right?

│   Test [256ae19c] 'sarscov2-nanopore' FAILED (9.769s)                                                                         │
│                                                                                                                               │
│   Assertion failed:                                                                                                           │
│                                                                                                                               │
│   1 of 2 assertions failed                                                                                                    │
│                                                                                                                               │
│   Nextflow stdout:                                                                                                            │
│                                                                                                                               │
│   Nextflow stderr:     

@SPPearce
Copy link
Contributor

The process tests passed, but the stability check still fails. It seems that redirecting the log file is not correct, right?

│   Test [256ae19c] 'sarscov2-nanopore' FAILED (9.769s)                                                                         │
│                                                                                                                               │
│   Assertion failed:                                                                                                           │
│                                                                                                                               │
│   1 of 2 assertions failed                                                                                                    │
│                                                                                                                               │
│   Nextflow stdout:                                                                                                            │
│                                                                                                                               │
│   Nextflow stderr:     

It may well mean that the log file contains a timestamp, and hence changes every time.
Let me take a look

modules/nf-core/porechop/abi/main.nf Outdated Show resolved Hide resolved
modules/nf-core/porechop/abi/tests/main.nf.test Outdated Show resolved Hide resolved
modules/nf-core/porechop/abi/tests/main.nf.test Outdated Show resolved Hide resolved
modules/nf-core/porechop/abi/tests/main.nf.test Outdated Show resolved Hide resolved
@SPPearce
Copy link
Contributor

No timestamp, but the last line of the log includes the full path:
Saved result to /workspace/modules/.nf-test/tests/7da04198d79b5b8b0117b170c3e2ef14/work/62/b69f2df1551d4b60ecf77f32ab8ab0/test.porechop_abi.fastq.gz
So we need to exclude this from the snapshot.
I can't push to your branch because it is on your own repo.

@LilyAnderssonLee
Copy link
Contributor Author

@SPPearce Is it ready to me merged?

check input and output are not same
Copy link
Contributor

@SPPearce SPPearce left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, looks good to me now.

@LilyAnderssonLee LilyAnderssonLee added this pull request to the merge queue Jul 30, 2024
Merged via the queue into nf-core:master with commit 870f9af Jul 30, 2024
12 checks passed
@LilyAnderssonLee LilyAnderssonLee deleted the porechop_abi_update branch July 30, 2024 12:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants