[Pulp-list] pulp.spec & rpmlint
Jay Dobies
jason.dobies at redhat.com
Wed Oct 26 18:01:08 UTC 2011
https://bugzilla.redhat.com/show_bug.cgi?id=672569
In fixing the above bug, I added a unit test that will run rpmlint
against our pulp.spec file. This way, even if we forget to run it when
changing the spec file, hudson should catch it for us.
The test name is test_rpmlint.py and a failure will have the message:
======================================================================
FAIL: Verifies rpmlint does not indicate any errors in pulp.spec.
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/jdob/code/pulp/test/unit/test_rpmlint.py", line 42, in
test_rpmlint
self.assertEqual(0, p.returncode, msg='rpmlint indicated one or
more errors in pulp.spec')
AssertionError: rpmlint indicated one or more errors in pulp.spec
So if you see that appear in either your local run or hudson, keep in
mind that we are now enforcing that rpmlint is happy with pulp.spec. If
you are making changes to the spec, running rpmlint is dirt simple and
is even easier than running the unit test:
# rpmlint pulp.spec
We currently have one warning that continues to be reported, but it's
just a warning (and I'm not sure the implications of changing Source0
and how that would affect tito). The important part is that the exit
code from rpmlint is 0. If it's not, there were one or more errors and
the unit test will fail too.
--
Jay Dobies
RHCE# 805008743336126
Freenode: jdob @ #pulp
http://pulpproject.org | http://blog.pulpproject.org
More information about the Pulp-list
mailing list