I'm getting started writing CWL tools and workflows. I would like to get a good testing framework setup from the beginning. Is there something that can help testing CWL? How are you testing CWL?
I saw cwltest exists. However, the documentation is very sparse. I haven't figured out what should go inside test-descriptions.yml. It is also not clear to me if this tool is just checking for syntax errors, or will it actually try to run a tool or a complete workflow.
Thanks, Carlos
2 answers
https://www.commonwl.org/#Editors_and_viewers lists tools to assist with CWL composition, including a graphical user interface and plugins for many popular IDEs (Atom, vim, emacs, Visual Studio Code, IntelliJ, gedit). Some of these plugins will do a basic syntax check for you as well.
Added as answer per @mr-c comment
Some suggestions would be:
Testing with cwltool and the --js-console and --debug options. Also using --tmp-outdir-prefix, -leave-tmpdir, and --leave-outputs to inspect results from intermediate steps
Having small sample inputs that can be used to run the workflows quickly when making changes
Testing the individual tools before the whole workflows
cwltool --validate to only validate the workflow and not run it
cwltool --print-dot and cwltool --print-rdf to show graph of the workflow
Log in to answer this question.
I don't have a full answer here, but some suggestions would be:
Testing with
cwltooland the--js-consoleand--debugoptions. Also using--tmp-outdir-prefix,-leave-tmpdir, and--leave-outputsto inspect results from intermediate stepsHaving small sample inputs that can be used to run the workflows quickly when making changes
Testing the individual tools before the whole workflows
cwltool --validateto only validate the workflow and not run itcwltool --print-dotandcwltool --print-rdfto show graph of the workflowcwltestis for the execution of CWL tools and workflows and comparing their outputs with an expected result or an expected failure.ionox0 comment should be changed to be an answer, as that is basically my response.
In case someone else lands here looking for the elusive
cwltestdocumentation: