Commit Graph
187 Commits
Author SHA1 Message Date
John Chilton 2aa7f04364 Replace __rip_value with dict.pop.
Thanks @bgruening.
2015-12-06 09:50:55 +00:00
John Chilton b11002bef3 Don't iterate over unused key.
Thanks to @bgruening.
2015-12-06 09:50:55 +00:00
Björn Grüning df64706544 Merge pull request #1237 from jmchilton/test_jobs_fix
Fix missing assertion pointed out @nsoranzo.
2015-12-06 00:57:11 +01:00
Björn Grüning 6126bd0e93 Merge pull request #1214 from jmchilton/format_2_1
Small enhancements in workflow inputs and outputs
2015-12-05 21:37:50 +01:00
John Chilton c91a2eb339 Multi data parameter improvements.
Allow multiple collections to be fed to a multi data parameter in one reduction step. Fixes #750 and will really simplify certain classes of tools.

Rebased original with fixes for rerun of such reductions.

Manually tested workflow execution and everything seems fine. The workflow editor already thought this was possible, so that is another bug corrected by this enhancement.

To run the associated API test, execute the following command:

./run_tests.sh -with_framework_test_tools -api test/api/test_tools.py:ToolsTestCase.test_reduce_multiple_lists_on_multi_data

Conflicts:
	static/maps/mvc/dataset/dataset-choice.js.map
	static/maps/mvc/form/form-select-content.js.map
	static/scripts/mvc/form/form-select-content.js
2015-12-04 20:41:21 +00:00
John Chilton 40e6932a25 Fix workflow API tests for workflow output changes. 2015-12-04 20:37:37 +00:00
John Chilton a597e0e834 Implement workflow outputs for format 2 workflow definitions.
Copy CWL style of specifying a outputs specification block at the top-level of the workflow specification and within that use the "source" attribute to specify the output. Reuse the specification used by "$link"s to describe this output - namely <label_or_order_index>[#<output_name=output>].
2015-12-04 20:34:57 +00:00
John Chilton 1bd0a4e970 Refactoring and more testing of format 2 workflow implementation code...
... toward more reusable design.
2015-12-04 20:34:57 +00:00
John Chilton 70a9f21393 Update workflow format 2 code with infrastructure for nesting runnables.
In downstream work this is used for subworkflows and nested tools. Not sure which of these would potentially hit main line Galaxy first so setting this all up in its own commit.
2015-12-04 20:34:57 +00:00
John Chilton b0b26e6901 Allow specifying Format 2 workflow by path.
This will allow importing workflow relative resources in subsequent passes at this.
2015-12-04 20:34:56 +00:00
John Chilton 4a279ffb64 Allow inputs section for Format 2 workflow definitions.
Arguably a more natural way to define inputs, regardless it allows more CWL-like input definitions for workflows.
2015-12-04 20:34:56 +00:00
John Chilton df781dcc18 Fix missing assertion pointed out @nsoranzo.
Lots of other tests would fail if simple uploads aren't working, but it is better to be direct and very explicit about why this particular test is failing.
2015-12-04 12:42:49 +00:00
John Chilton 1adff983f2 Wait on jobs and history in certain API test cases.
This strategy proved to work around certain race conditions in tool testing so hopefully it will solve the transiently failing job searching and filtering test cases.
2015-12-03 16:33:45 +00:00
John Chilton dd5f3aec52 Fix workflow extraction test cases broken with 77ed5681f8 2015-12-03 09:55:45 +00:00
John Chilton 77ed5681f8 Extend base api workflow _run_jobs helper...
... to allow loading content from test-data files.
2015-12-01 20:17:10 +00:00
Martin Cech ab0829f2e8 Merge pull request #1096 from jmchilton/format_2
Outline "Format 2" workflow definitions.
2015-11-20 22:05:42 -05:00
John Chilton b4c77b7617 Introduce "Format 2" workflow definitions.
This is a slight tightening up of the ad-hoc, experimental workflow YAML definition used by the test framework (and by Kyle, but lets just admit Kyle is part of Galaxy's test framework).

This format is still defined entirely client side by transcoding the YAML or python object description into real (or format 1) Galaxy workflows - so these cannot realisticaly be declared part of Galaxy's public interface and can remain experimental and subject to change.

In addition to refactoring the code implementing these workflows for upstream modifications to explore new features, the format itself has been made slightly more stringent in two ways:

 - 'steps' must now be explicit (previously converted auto-convert list to dict).
 - Ensure the workflow declared a 'class' is defined and the class is 'GalaxyWorkflow'.

This will help with discovery of workflow objects with downstream tooling (planemo for workflows?) and brings the Galaxy definition slightly more inline with the CWL definition for workflows (very slightly).
2015-11-18 10:50:43 +00:00
Dannon Baker 3d933edd32 Merge pull request #1074 from martenson/lib-api-tests
[WIP] add more data libraries API tests
2015-11-17 20:59:29 -05:00
Nate Coraor d8152f3336 Merge branch 'release_15.10' into dev 2015-11-17 11:37:05 -05:00
Martin Cech 43dc7a52e5 add more API tests for data libraries 2015-11-12 12:34:57 -05:00
John Chilton 177f73fcdb Fix lower timeout caught by @nsoranzo. 2015-11-11 14:43:51 +00:00
John Chilton e4c9f06d3b Attempt to fix timing out tests.
Continuation of work started by @nsoranzo here 92a152d89c. In addition to increasing the max timeout it will now print the timeout in the assertion error so we can see if it is being overridden and attempt to adjust timeouts too small.
2015-11-11 11:37:21 +00:00
guerler b2723e7467 Disable invalid test case. Add validation criteria.
Fix comments

Fix comment
2015-11-10 15:36:55 -05:00
John Chilton 5c7dd75fd0 Refactor test dataset populator for reuse on jobs without outputs. 2015-11-02 07:32:17 +00:00
Martin Cech b6f3783acd remove test_map_over_two_collections_legacy as it is obsolete 2015-10-15 11:29:06 -04:00
guerler 8cb894b34a Fix data library test case
Fix library data test case
2015-10-12 17:07:14 -04:00
Martin Cech 2b966ca4fa Merge pull request #859 from jmchilton/test_fix_2
Attempt to fix more transiently failing API tests.
2015-10-06 15:16:41 -04:00
Dannon Baker a2a4ce43ec Merge pull request #743 from jmchilton/cross_product_collection_mapping
Extend tool API to allow cross product mapping over collections.
2015-10-06 13:40:49 -04:00
John Chilton e9d77ac763 Attempt to fix transiently failing API tests.
- Fix default timeout of wait_on_state api helper. Had the wrong default specified and might fix this failure: https://jenkins.galaxyproject.org/job/docker-api/229/testReport/junit/api.test_libraries/LibrariesApiTestCase/test_create_dataset/
 - Modify job search test case to allow a little more time between the history being "ok" and the job, in case there is a timing condition if the HDA is committed first and then job. Also improve the test output in case this isn't the problem.
2015-10-06 14:44:50 +01:00
John Chilton 5ff102507b Add regression test for issue in #798. 2015-09-25 14:29:05 +01:00
John Chilton fa0c3a4bbc Implement failing workflow test case.
For galaxyproject/galaxy#776.
2015-09-24 15:40:52 +01:00
John Chilton 684be5f6a5 Functional test to verify RData is not decompressed in upload process. 2015-09-23 13:56:14 +01:00
carlfeberhard a90a4fceba Merge pull request #755 from jmchilton/hdca_structure_state_tracking
Improved state tracking of HDCA in history panel.
2015-09-23 12:05:59 -04:00
John Chilton 87d5063a0d Implement min/max for multiple data input parameters. 2015-09-21 15:51:58 +01:00
Martin Cech 2e55eb11e5 Merge pull request #758 from jmchilton/framework_tests
API Test Fixes
2015-09-19 15:03:28 -04:00
John Chilton 45d5e29c1d Extend test_map_over_two_collections timeout.
May be the cause of intermittent test failure on jenkins (https://jenkins.galaxyproject.org/job/G-API/lastCompletedBuild/default/testReport/api.test_tools/ToolsTestCase/test_map_over_two_collections/).
2015-09-19 11:55:12 +01:00
Nicola Soranzo 92a152d89c Uniform and slight increase the default timeout of API tests. 2015-09-18 17:48:59 +01:00
John Chilton ef23abc6df WIP: Improved state tracking of HDCA in history panel.
For tools which dynamically discover datasets for an output collection, keep the collection yellow until the structure of the HDCA has been fully defined. HDCAs still have the problem that they will always be green even if datasets contained within are in error, running, or queued states - but at least the structure is now reflected in the color.
2015-09-18 16:28:22 +01:00
John Chilton 84b5726ca9 Extend tool API to allow cross product mapping over collections.
By default if single data parameters are mapped over by collections, the collections are matched up (e.g. for two collections the items are paired off and two collections of dimension (N) will result in running N jobs and producing an (N) dimensional output for each define output). In the parameter meta value wrapper (where batch mode can be set with the ``batch`` flag), the linked flag is now respected for collection operations. If ``linked`` is ``False``, then the cross product of the inputs will be used to map over the tool. In the above simplest case, this would cause an NxN (``list:list``) collection to be created for each tool output.

This operation was previously available for individual datasets, but when supplied a collection it would not create an implicit collection pulling together all the relevant datasets with the correct structure - it would just run the jobs and leave the datasets uncollected. Now a collection with the correct structure and identifiers is created.

Limitations:
-----------------

This does not enable tool form support but the API for collections matches that for doing cross product operations over sets of individual datasets, so once support is added to the tool form for that collection support should be trivial.

Testing:
-----------------

The following test case has been extended to now ensure that an implicit collection is created and that it has the right dimensionality/structure and contents.

    ./run_tests.sh -with_framework_test_tools -api test/api/test_tools.py:ToolsTestCase.test_map_over_two_collections_unlinked
2015-09-18 09:47:44 +01:00
Nicola Soranzo 3fafbb5e34 Fix more MissingToolException when running "./run_tests.sh -api" without "-with_framework_test_tools". 2015-09-15 16:47:40 +01:00
Nicola Soranzo 65519718b3 Fix "KeyError: name" error when running "./run_tests.sh -api".
Example traceback for test/api/test_workflows.py:WorkflowsApiTestCase.test_workflow_run_dynamic_output_collections :

galaxy.web.framework.decorators: ERROR: Uncaught exception in exposed API method:
Traceback (most recent call last):
  File "/opt/galaxy/lib/galaxy/web/framework/decorators.py", line 260, in decorator
    rval = func( self, trans, *args, **kwargs)
  File "/opt/galaxy/lib/galaxy/webapps/galaxy/api/workflows.py", line 182, in create
    return self.__api_import_new_workflow( trans, payload, **kwd )
  File "/opt/galaxy/lib/galaxy/webapps/galaxy/api/workflows.py", line 374, in __api_import_new_workflow
    workflow, missing_tool_tups = self._workflow_from_dict( trans, data, **from_dict_kwds )
  File "/opt/galaxy/lib/galaxy/web/base/controller.py", line 1111, in _workflow_from_dict
    publish=publish
  File "/opt/galaxy/lib/galaxy/managers/workflows.py", line 165, in build_workflow_from_dict
    missing_tool_tup = ( step_dict[ 'tool_id' ], step_dict[ 'name' ], step_dict[ 'tool_version' ] )
KeyError: 'name'
2015-09-11 19:05:37 +01:00
Nicola Soranzo 760899f9c0 Fix MissingToolException when running "./run_tests.sh -api" without "-with_framework_test_tools". 2015-09-11 19:05:37 +01:00
Nicola Soranzo 9805294f97 Revert "Revert "[WIP] Mega flake8 linting""
This reverts commit 37f1976d38.
2015-07-12 21:25:44 +01:00
Dannon Baker 37f1976d38 Revert "[WIP] Mega flake8 linting" 2015-07-11 13:17:38 -04:00
Bjoern Gruening eced982622 lint fixes for /test/api/ 2015-07-05 19:50:48 +01:00
Dannon Baker 032dd3e3fd Merge branch 'release_15.05' into dev 2015-06-16 14:44:37 -04:00
John Chilton ea0d5a9c86 Fix bug with runtime post job actions.
Runtime post job actions are post job actions inserted when the workflow is invoked instead of being part of the workflow object in the database. The bug noticed by @kellrott was that these actions were being appended to the original workflow post job actions instead of being transient things just attached to the jobs themselves.

This fixes that problem and adds a test to try to prevent regressions.
2015-06-16 14:18:11 -04:00
Dannon Baker 8c3fdaa874 Merge 15.05 to dev 2015-06-01 14:14:02 -04:00
John Chilton 44c8e74c29 Fix tag creation via /tags API endpoints.
Add test case to at least check for exceptions such as those reported.

Closes galaxyproject/bioblend#145.
2015-05-25 22:31:09 -04:00
John Chilton 308a8e3737 Merge remote-tracking branch 'galaxyproject-careful/release_15.05' into dev
Conflicts:
	config/plugins/interactive_environments/ipython/config/ipython.ini.sample
2015-05-15 13:41:29 -04:00