Commit Graph
136 Commits
Author SHA1 Message Date
Nicola Soranzo 95ccefacb8 Improve type annotations for model store
and related files.

Follow-up on https://github.com/galaxyproject/galaxy/pull/14971 .
2022-11-30 01:45:56 +00:00
John Davis 29053fa9e4 Move test_dbscript into app
JUSTIFICATION:
As per @jmchilton:
The package tests should pretend they don't have galaxy_directory()
available because they're meant to be installed into a Python env.
This test is fundamentally not testing anything about the Galaxy data
package - it is testing scripts placed in Galaxy root directory and that
would not be available in an installed Galaxy environment.
2022-11-21 18:12:04 -05:00
John Davis 4e5a94a2b2 Use resource_path for test_dbscript 2022-11-21 18:12:04 -05:00
John Davis faf8efafd0 Use resource_path for test_migrations 2022-11-21 18:12:04 -05:00
John Davis dd267e2d3e Refactor test, use galaxy_directory() 2022-11-21 18:12:04 -05:00
John Davis 821b60f30a Use galaxy_directory() instead of hacking the path 2022-11-21 18:12:04 -05:00
John Chilton dac9f39266 Move model/mapping utils into packaged code for reuse by the tool shed. 2022-10-29 12:07:46 -04:00
davelopez 881c57eb64 Fix export history RO-Crate without workflows
The workflows_directory may not exists if no workflow was invoked in the history.

Includes unit test + small tests refactor
2022-10-21 10:25:32 +02:00
Marius van den Beek 934369aa3a Merge pull request #14792 from jdavcs/dev_sqlalchemy_engine_options
Make connect_args for SQLAlchemy's engine configurable
2022-10-17 10:30:44 +02:00
John Davis d957e143ea Engine options are never null 2022-10-14 15:27:20 -04:00
John Davis 7578edbd00 Fix mypy error 2022-10-14 13:31:54 -04:00
John Davis da87ca9209 Allow to set connect_args for SQLAlchemy's engine in config 2022-10-14 13:17:42 -04:00
davelopez 0356c2e01f Add unit test for api_keys.deleted column 2022-09-30 16:39:12 +02:00
John Davis 1eb4d15f38 Split script into admin and dev
TODO: remove duplication between db.py and db_dev.py (split into
multiple commits is intentional)
2022-09-16 00:39:44 -04:00
John Davis b6a5286487 Rename db.sh > manage_db.sh, following code review feedback 2022-09-16 00:39:44 -04:00
John Davis 3c094790a1 Update test comments 2022-09-16 00:39:03 -04:00
John Davis 372d4af0b8 Add type hints 2022-09-16 00:39:03 -04:00
John Davis 1f5b0e6bba Drop LegacyScripts: no longer used 2022-09-16 00:39:03 -04:00
John Davis 7e238bf591 Add --raiseerr option; hide error traceback by default 2022-09-16 00:39:03 -04:00
John Davis 959bc49e66 Add missing tests 2022-09-16 00:39:03 -04:00
John Davis 0745e2e05c Fix mypy by asserting object before accessing its attributes 2022-09-16 00:39:03 -04:00
John Davis 89f753767b Fix packages tests: script is one level up 2022-09-16 00:39:03 -04:00
John Davis ac6b0ceee0 Fix linting 2022-09-16 00:39:03 -04:00
John Davis 0a798ea536 Test against 1 or 2 databases 2022-09-16 00:39:03 -04:00
John Davis b30e4e14ae Add inline testing documentation 2022-09-16 00:39:03 -04:00
John Davis a69ab407a6 Add initial draft 2022-09-16 00:39:03 -04:00
John Davis 6abc9dc1c5 Refactor get_alembic_cfg: make available to other code 2022-09-16 00:39:03 -04:00
John Chilton 3dbe2891e7 Implement RO Crate export of Galaxy histories and invocations. 2022-09-13 19:20:48 -04:00
John Davis def882932d Add verify_db_is_initialized function; tests 2022-07-13 16:10:58 -04:00
John Davis 1e75d85fd4 Prevent accessing LegacyScripts.database before processing script args 2022-07-13 15:40:42 -04:00
Sergey Golitsynskiy bf91dc5b75 Remove column update_time from model, tests 2022-06-01 18:30:30 -04:00
John Chilton c5bf63bc91 Add DEFERRED datasets to Galaxy
- Improves options and display around discarded datasets.
- Adds new APIs for importing model stores.
- Adds support to model store layer for importing/exporting workflow invocations and APIs and tests to support this.
- Add new DEFERRED dataset state - with APIs for materializing them or the option to defer them on the worker node if using tool_evaluation_strategy=remote on the job destination.
- UI and API options for uploading deferred datasets individually or into collections.
2022-05-23 19:48:47 -04:00
Sergey Golitsynskiy 34e8b182d4 Map Dataset declaratively 2022-04-29 13:37:32 -04:00
Sergey Golitsynskiy cc1c2e4b94 Enable postgresql testing for new annotations module 2022-04-20 22:16:40 -04:00
Sergey Golitsynskiy e9eb6c1500 Proof of concept: replace annotation mapping tests 2022-04-20 18:14:43 -04:00
Sergey Golitsynskiy 254830a33b Add fixture for WorkflowStepAnnotationAssociation 2022-04-20 17:48:37 -04:00
Sergey Golitsynskiy ed2798e044 Fix module path for remote unit tests 2022-04-20 17:03:03 -04:00
Sergey Golitsynskiy 52bb6c90e6 Fix linting 2022-04-20 16:23:05 -04:00
Sergey Golitsynskiy 95a4fd5667 Use plugins instead of importing fixtures directly
Also handle setting the fully qualified module name depending on wht's
the cwd from which the test is executed.
2022-04-20 15:50:52 -04:00
Sergey Golitsynskiy c9e3d340f6 Move tmp_dir fixture one level up
Otherwise url_factory is not usable outside of migrations
2022-04-20 10:28:03 -04:00
Sergey Golitsynskiy 1228bfa769 Refactor code for dropping postgres 2022-04-20 10:28:03 -04:00
Sergey Golitsynskiy 495dd6daaf Move last context managers out of migrations 2022-04-20 10:28:03 -04:00
Sergey Golitsynskiy c3059de4a5 Move disposing_engine out of migrations 2022-04-20 10:28:03 -04:00
Sergey Golitsynskiy eec0a87028 Move url_factory out of migrations
Make available for use in other testing contexts.
2022-04-20 10:28:03 -04:00
Sergey Golitsynskiy 476da34b7a Move test revisions into testing_utils 2022-04-20 10:28:03 -04:00
Sergey Golitsynskiy f5c962d8d7 Move common.py to testing_utils 2022-04-20 10:28:03 -04:00
Sergey Golitsynskiy d2ecb7ee68 Fix linting (unused import) 2022-04-20 10:28:03 -04:00
Sergey Golitsynskiy 0a7d2113bd Factor out helper function (kill more dups) 2022-04-20 10:28:03 -04:00
Sergey Golitsynskiy 9ae2d4e08f Simplify (no need for scoped_session), consolidate redundant fixtures 2022-04-20 10:28:03 -04:00
Sergey Golitsynskiy 1a95857271 Rename test modules for testing_utils 2022-04-20 10:28:03 -04:00