-
Notifications
You must be signed in to change notification settings - Fork 122
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
Discover from dist-git source should explore metadata under the source directory #978
Comments
Thank you for the report, I'll try to create a fix this week. New option
|
The |
I have a possibly separate problem with |
That is a bit different I'm afraid. In that case you are not expected to search for any tests in the extracted sources, right? |
I think I figured it out. The differences between plans and tests aren't obvious and I got it working by putting the actual test execution into tests/unit.fmf and the setup with dist-git-source into a corresponding plan under plans/
Right, the tmt tests are in dist-git. |
Just realized one aspect which will probably make the implementation less straightforward: If I remember correctly, there can be multiple source tarballs included in the |
Needs more time to evaluate possible corner cases |
Would it be possible to provide a solution for a single/first tarball, i.e. look at |
For those following along, I created this hack and successfully tested it: https://github.com/cockpit-project/cockpit/pull/17378/files (but.. eww!) |
Fedora dist-git FMF test plans have to specify a git repo and fixed ref for where to find the tests to run. This is bad, and at some point it should instead just discover the tests from the upstream source tarball instead. Until teemtee/tmt#585 gets fixed, we need to bump `ref:` in dist-git's plans/upstream.fmf. Cockpituous had a hack for this [1], which we need to transplant to packit now. Unfortunately this reintroduces `files_to_sync:`, but all of this will go away when the follow-up issue teemtee/tmt#978 gets addressed. Create the file in tmp/ instead of plans/ (from where it would be easier to sync) as packit refuses operation on an unclean tree. tmp/ is in .gitignore. [1] cockpit-project/cockpituous@2ef3f6c9991
Fedora dist-git FMF test plans have to specify a git repo and fixed ref for where to find the tests to run. This is bad, and at some point it should instead just discover the tests from the upstream source tarball instead. Until teemtee/tmt#585 gets fixed, we need to bump `ref:` in dist-git's plans/upstream.fmf. Cockpituous had a hack for this [1], which we need to transplant to packit now. Unfortunately this reintroduces `files_to_sync:`, but all of this will go away when the follow-up issue teemtee/tmt#978 gets addressed. Create the file in tmp/ instead of plans/ (from where it would be easier to sync) as packit refuses operation on an unclean tree. tmp/ is in .gitignore. [1] cockpit-project/cockpituous@2ef3f6c9991
Could you try with #1128 please? I believe having more sources doesn't matter for that implementation. |
Should be covered by #1128. |
@psss, @lukaszachy : Sorry for the late reply, sprint week and long weekend. I'm super happy to see this, thanks! Does this still need a release, or does the Testing Farm use git? I. e. time to retry https://src.fedoraproject.org/rpms/cockpit-machines/pull-request/4# now or later? Thanks! |
I've just pushed out bodhi updates. It should get to the Testing Farm around tomorrow. |
Thanks @psss! We collided, I rebased https://src.fedoraproject.org/rpms/cockpit-machines/pull-request/4 an hour ago, and it still failed. Nice! Then I'll retry with 1.14.0 once that lands. |
Currently the source tarball is unpacked under the
discover/default/tests
directory and test discover is done from there. This brings two problems:.fmf
directory it is ignored as a nestedfmf.Tree
.We should discover tests directly from the unpacked directory and make sure that it has metadata tree root defined, e.g. call
tmt init
if needed.@martinpitt ran into this problem when working on this cockpit pull request.
The text was updated successfully, but these errors were encountered: