-
Notifications
You must be signed in to change notification settings - Fork 6
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
WIP: Test Fedora integration #10
base: master
Are you sure you want to change the base?
Conversation
@voxik WDYT? |
Sorry, but having .spec file, especially .spec file which might resemble any production .spec file is no-go. Spec files have to be in Fedora dist-git for reasons such as mass rebuilds/fixes. Alternatively, if it was somewhere buried alongside packit configuration, that might be acceptable.
Actually I don't really know. After last updates to fix the Ruby 2.7 compatibility, the test has much better coverage. |
You don't need to have the spec file here and can download it from dist-git on-the-fly: actions:
post-upstream-clone: "wget https://src.fedoraproject.org/rpms/abrt-ruby/raw/master/f/abrt-ruby.spec" With the line above, whenever packit service clones this repo and checks out a specific PR, it runs the specified command - downloads the spec and uses it further. |
@TomasTomecek WRT that |
Right. Let's say I move the
Great! Let's stick with the |
This is harder ... |
Yes, well, not sure packit has support for it.
We need also remove
|
@voxik I've fixed the paths and added disclaimer into spec file. Test: pvalena#8 This should work until end of month with TMT (instead of You can also run a test with:
Using |
- fedora-all | ||
actions: | ||
create-archive: | ||
- bash -c "gem build *.gemspec; mv -f *.gem ci/; ls ci/*.gem" |
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.
Ugh, I had old .gem files lying around and now they are moved to ci/
folder, that is not nice
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.
If only RubyGems were not so broken 🤯
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.
Oh, I didn't think of that. But I'm glad I didn't have anything like rm *.gem
there in the beginning.
Unfortunately, I couldn't think of any other (generic) way to do it. Ideally, there wouldn't be any of moving, or changing directories, but the .gem
file needs to be in ci/
folder for packit to find it (not sure whether that's a bug; I noted that in some issue, but maybe it's in it works, don't touch it
state).
Creating the gem using -C
would definitely help. Thanks for starting that thread, and creating PR!
I missed those questions somewhat. We are using copr to run builds and I'm not sure if we can pass args to mock/rpmbuild - I haven't seen any option for that. |
It's not an argument for mock(but for |
Needs packit "Github Application" (service) enabled.
Currently Testing Farm requires Packit, which requires the RPMS to be build, to be able to run the tests. Packit team is working on simple config which would be able to use spec file from Fedora dist-git. Anyway I'm not sure what to do about the
Source1
in that case, so having a spec file copy (or some dummy spec file) in this repo would be benefitial.Testing Farm has the resulting RPMS installed, and can run any integration tests (testing actual runtime in Fedora), including kernel-dependent tests or those that require network connection.
Do you have any idea for integration test that's missing?
Note: the test logs are currently displayed using a bit inconvinient UI, but the files themselves are accessible as well.
You can test this locally by running f.e.:
Note:
-vv
shows actual test output, which is otherwise omitted, but you can display it even after the run, without re-executing like so:tmt run -l report -fvvv
.In this PR does not include Tests metadata (test suite is executed using simple
execute:
script inplan
metadata instead).Ideally we would add
test
metadata (can be an test itself as well). That would mean one (or more, depends on us) additional file with test descriptions etc.. There are several metadata "forms" to choose from.Alternatively, tests can be run from plan ilke so (but those can't be pulled from Fedora f.e.), or using
execute
(currenlty only single test).Afterwards, the same test suite (living actually in github) can be easily run from Fedora (when CI gets is enabled). Anyway, AFAIK this can be done even without any metadata present in upstream repo as well (not recommended).
Examples:
This test suite, passing
This test suite, failing
Example Fedora configuration
Example Test metadata (simple, multiple tests)
Example Test metadata (advanced, single, uses inheritance)