-
Notifications
You must be signed in to change notification settings - Fork 11
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
fileinstall: remove asyncio logic #276
Conversation
2882d26
to
94b5a2f
Compare
Note: this one needs to be merged before this can be tested: #292 |
|
* Rose will now take over the role of managing its event loop. * Addresses cylc#274
94b5a2f
to
7a648a4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Read changes
- Run tests locally
- Tried to break various components of this
Now kicking tests |
:( |
Strange that it's passing locally. Does it want something like this? diff --git a/tests/functional/test_rose_stem.py b/tests/functional/test_rose_stem.py
index 0e23a73..ebf15f7 100644
--- a/tests/functional/test_rose_stem.py
+++ b/tests/functional/test_rose_stem.py
@@ -373,14 +373,14 @@ class TestProjectOverride():
"SOURCE_FOO_MIRROR=\"fcm:foo.xm/trunk@1\"",
]
)
- def test_project_override(self, project_override, expected):
+ async def test_project_override(self, project_override, expected):
"""Check that assorted variables have been exported.
"""
if expected == 'run_ok':
assert project_override['run_stem'].returncode == 0
else:
expected = expected.format(
- workingcopy=project_override['workingcopy'],
+ workingcopy=(await project_override)['workingcopy'],
hostname=HOST
)
assert expected in project_override['jobout_content'] |
This ticket is the gift that just keeps giving 🤦 Shouldn't need to await a fixture, doesn't make sense. It doesn't look like pytest-asyncio is actually installed?! |
I'm not convinced these tests were being run properly before. Note pytest-asyncio wasn't installed in CI (it is for us locally because of cylc-flow). I've now added pytest-asyncio back in as a test dependency and addressed some unrelated fixture scoping issues that were causing some failures. |
* The Cylc install and reinstall interfaces are now async. * This adapts rose-stem to handle the change and adjusts the tests.
a561037
to
5c0129e
Compare
5c0129e
to
f8bd554
Compare
f8bd554
to
2bdd234
Compare
2bdd234
to
1111aae
Compare
yield rose_stem_run_template(rose_stem_opts) | ||
|
||
|
||
class TestBasic(): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These test classes aren't achieving anything since they each contain only one test and don't manage any resources.
Test classes date back to unittest
, fixtures are more modern solution. Working with module-scoped fixtures and class-scoped tests gets tricky.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All's well that ends well
@wxtim, you might want to take a quick look at the test changes since you last reviewed. I've added pytest-asyncio as a test dependency (I have no idea what the tests were doing before?) and dealt with some fixture scoping issues that required some test changes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Re-reviewed! 😄
This is one of a triplet of PRs which closes #274
See the cylc-flow PR for testing instructions.
Check List
CONTRIBUTING.md
and added my name as a Code Contributor.setup.cfg
(andconda-environment.yml
if present).CHANGES.md
no - unreleased bug?.?.x
branch.