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 test scripts #70

Merged
merged 17 commits into from
Oct 8, 2024
Merged

Add test scripts #70

merged 17 commits into from
Oct 8, 2024

Conversation

kretep
Copy link
Contributor

@kretep kretep commented Oct 3, 2024

This adds mainly:

  • a script (test.sh) that traverses all the tools, executes their CWL description with the provided input.yml, and reports test results.
  • a github actions workflow to execute the tests

@kretep kretep requested a review from vedran-kasalica October 3, 2024 13:27
@kretep
Copy link
Contributor Author

kretep commented Oct 3, 2024

The tests are failing as expected, as the sage config.json is not available on main yet.

Copy link
Member

@vedran-kasalica vedran-kasalica Oct 3, 2024

Choose a reason for hiding this comment

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

Do we want to have this file in the repo? If I understood correctly, actions using act do not work locally, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I removed it, since it's mainly for convenience and only one command.

I guess in theory it could work, but it failed because of Docker in Docker limitations. You'd have to mount the docker socket inside the first container somehow, but I didn't manage to get it working.

test.sh Outdated
Copy link
Member

@vedran-kasalica vedran-kasalica Oct 3, 2024

Choose a reason for hiding this comment

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

Does it make sense to move this script to .github? I am not sure what is the policy of .github content. It would also be nice to rename the script to something a bit more descriptive.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The idea is that the script is also runnable locally (it is) if you want to run the tests, so I wouldn't put it in .github. What would you suggest for a name? Maybe we should move it to a test folder or something

Copy link
Member

Choose a reason for hiding this comment

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

I see, in that case I would suggest maybe naming it test_cwl_annotations.sh, what do you think? If the idea is that you can test it locally, we should add a line in the readme that describes how (and why) to run it locally.

I guess the following 3 would be sufficient:

  • a line describing the script
  • mention the cwltool dependency
  • provide a command on how to run it

Copy link
Contributor

Choose a reason for hiding this comment

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

I agree with a more specific name, since there are probably many test.sh scripts around.

Copy link
Member

@vedran-kasalica vedran-kasalica left a comment

Choose a reason for hiding this comment

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

The added tests are really useful, and the only thing that I would recommend updating is the test.sh and the readme to document it (as discussed in the comments). After that, the PR can be merged.

@kretep kretep merged commit 68f993a into main Oct 8, 2024
1 check failed
@kretep kretep deleted the add-test-scripts branch October 8, 2024 14:38
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.

3 participants