Overview
Request 625014 accepted
Add package installation and post-install self-test
- Created by okurz
- In state accepted
- 5 package maintainers
- Supersedes 622577
If the additional if/else branches within the same spec file are too messy we can also add another spec file for testing next to the original one, e.g. as in https://build.opensuse.org/package/view_file/devel:openQA/openQA/_service:obs_scm:openQA-test.spec?expand=1
Are the intention of these changes to allow OpenQA-Testing? Why was the package renamed?
No, has nothing to do with openQA-testing. The package was not renamed. Just in the header the automatic spec-file cleaning updated the name. I do not know if I can prevent this.
What about moving everything to the %check
block? Then it is separated, run each time after the build step and should be less messy.
No, this can not work and is not the same test. http://s.qa/2k18l1-okurz might also give you a bit of insight. All tests within the %check section are executed in the build-environment. What we should have is a clean environment in which you install the package and execute tests after installation of the package.
As stated in the first comment, If you think the many %if/%else within the same file are messy we could go with a separate spec-file as in openQA.
I would like the package to cover an installation test as well an post-deployment test which we would need otherwise to cover in openQA tests which would be more tedious for this use case and you would not to work on crappy bugreports by me instead of fast feedback from package self-tests ;)
A separate spec seems better.
hm, might need a _multibuild file after all …
ok, _multibuild is not allowed in parallel to test spec file "ERROR: we support EITHER _multibuild OR multiple spec files. Do not add both" from source_validator. But why is the test spec file not picked up then?
ok, had to call
osc linkpac home:okurz:branches:Cloud:Tools cf-cli home:okurz:branches:Cloud:Tools cf-cli-test
and probably need to submit the project, not just a package.After acceptance of the SR it might be necessary to call the "linkpac" command in the destination project as well.
@alfred-jenkins, @svollath, @thardeck: review reminder