[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[Pulp-list] pulp.spec & rpmlint



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


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]