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

Make module template and test_yml_builder default commands match. #1568

Merged
merged 3 commits into from
May 12, 2022
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
- Removed retry strategy for AWS tests CI, as Nextflow now handles spot instance retries itself
- Add `.prettierignore` file to stop Prettier linting tests from running over test files
- Add actions workflow to respond to `@nf-core-bot fix linting` comments on pipeline PRs
- Made module template test command match the default used in `nf-core modules create-test-yml` ([#1562](https://github.com/nf-core/tools/issues/1562))

### General

Expand Down
2 changes: 1 addition & 1 deletion nf_core/module-template/tests/test.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
## TODO nf-core: Please run the following command to build this file:
# nf-core modules create-test-yml {{ tool }}{%- if subtool %}/{{ subtool }}{%- endif %}
- name: "{{ tool }}{{ ' '+subtool if subtool else '' }}"
command: nextflow run ./tests/modules/{{ tool_dir }} -entry test_{{ tool_name_underscore }} -c ./tests/config/nextflow.config -c ./tests/modules/{{ tool_dir }}/nextflow.config
command: nextflow run ./tests/modules/{{ tool_dir }} -entry test_{{ tool_name_underscore }} -c ./tests/config/nextflow.config
tags:
- "{{ tool }}"
# {%- if subtool %}
Expand Down
4 changes: 1 addition & 3 deletions nf_core/modules/test_yml_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,9 +164,7 @@ def build_single_test(self, entry_point):
ep_test["name"] = rich.prompt.Prompt.ask("[violet]Test name", default=default_val).strip()

while ep_test["command"] == "":
default_val = (
f"nextflow run tests/modules/{self.module_name} -entry {entry_point} -c tests/config/nextflow.config"
)
default_val = f"nextflow run ./tests/modules/{self.module_name} -entry {entry_point} -c ./tests/config/nextflow.config"
if self.no_prompts:
ep_test["command"] = default_val
else:
Expand Down