conu icon indicating copy to clipboard operation
conu copied to clipboard

add a single make target to verify all packaging methods

Open TomasTomecek opened this issue 7 years ago • 2 comments

Introduce a new make target: $ make check-packaging.

This target should verify that:

  • [ ] python packaging works (conu can be installed using pip2 install . and pip3 install . and then just smoke-test it can imported)
  • [ ] RPM packaging works (we can build an RPM from existing code in git repo (make srpm)); this means that we can build and install conu for these platforms:
    • [ ] EPEL (CentOS 7)
    • [ ] Latest Fedora stable release (28 right now)
    • [ ] Fedora rawhide
    • [ ] install the package after it is built and smoke-test it the same way as for python packaging

We've already done some work in this area so it's possible that some of these tasks are (mostly) done.

When working on this, please make sure it fits in the current testing architecture (make targets, test structure, etc.). Also, all the build and install steps are expected to be performed in a container.

Please comment if you have any questions.

TomasTomecek avatar Jan 03 '18 11:01 TomasTomecek

Hi Tomas, I have some questions :nerd_face:

  1. I'm not sure how to integrate all... $ make check-packaging should get conu from pip2 and pip3, run all the tests and then integrate with make srpm :thinking:
  2. I thought that Conu doesn't work on CentOS 7.
  3. Should this new make target run all the scripts inside examples/?

enriquetaso avatar Mar 15 '18 06:03 enriquetaso

Hi Laura, thank you for your interest and contributions!

I'm not sure how to integrate all... $ make check-packaging should get conu from pip2 and pip3, run all the tests and then integrate with make srpm thinking

That would be ideal but at the same time it would take a lot of time to run the whole test suite on every platform. Packaging tests should just verify that conu is installable and can be imported after it's installed, soemthing like:

$ pip3 install --user .
$ python3 -c "import conu"

With this, we would know that python packaging still works. Next test would be to validate RPM packaging:

$ make rpm-in-mock-f27

With such check, we would know that conu can be built in Fedora 27 buildroot. Once it's built, install it in a fedora:27 container and just try to import it the same way as above.

I thought that Conu doesn't work on CentOS 7.

It does! We made it work. If it doesn't, it's a bug and we need to fix it. See release notes for 0.2.0.

Should this new make target run all the scripts inside examples/?

As I wrote above, for the start it's enough to just smoke-test the installation with python -c "import conu". Once we get access to some powerful CI system, we could start running the complete test suite on every platform we intend to support. It's not fun to open a pull request and wait an hour to get results from CI.

TomasTomecek avatar Mar 15 '18 09:03 TomasTomecek