* Save disk space on dev host by avoiding `docker pull mattdm/fedora'
* Save time by not building a fedora 19 image and running its tests
We can always revert this commit if we need to run tests on f19.
Use the "semi-official" base image for rawhide.
It appears to be updated on a regular basis.
This gives us advance warning of breaking changes
in the bleeding-edge version of fedora.
Ensure build deps are consistent across the spec file and test harness.
Note: http://fedoraproject.org/wiki/HOWTOFindMissingBuildRequires
says that some packages should not be BuildRequires because
"they would occur too often" and "are considered the minimum build
environment." However, Docker changes the scope of that assumption
to keep docker images small.
* asciidoc indirectly requires docbook-style-xsl on el6 and f20,
but not on el5. Resolve failure to build tito with tito on el5:
"I/O error : Attempt to load network entity"
* Resolve "egg missing file" on el5 due to busted symlinks
from 20c4f1b7c0.
* Add functional test to build tito with itself in order to
catch problems like the ones above.
Closes https://github.com/dgoodwin/tito/issues/133
Alas, python3 doesn't have the cmp() function.
Support both python2 and python3 for comparisons using tip from
https://docs.python.org/3.0/whatsnew/3.0.html#ordering-comparisons
Avoids TB on python3:
======================================================================
ERROR: test_compare_version (unit.common-tests.ExtractBugzillasTest)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/sandbox/test/unit/common-tests.py", line 224, in test_compare_version
self.assertEquals(0, compare_version("1", "1"))
File "/home/sandbox/src/tito/common.py", line 689, in compare_version
return cmp(normalize(version1), normalize(version2))
NameError: global name 'cmp' is not defined
run_command_print originally used trailing comma to suppress newline,
but python3 needs a named argument (`end=`) [1].
38446dca added 'from future...' to support python3's `end=` argument,
but the import causes error on el5:
SyntaxError (future feature print_function is not defined
6b9787e2 introduced an approach to strip newlines compatible
with both el5's python2 and fedora 20's python3.
This means we don't need the future import any more, and
we can safely remove it to restore el5 compatibility.
[1] https://docs.python.org/3.0/whatsnew/3.0.html#print-is-a-function
Lost this somehow in refactoring, but right now failed commands are silent.
Raise an exception and print the error details.
Restore behaviour where we can print command output on success if desired.
Fix a couple tests that were actually failing due to missing rsync dest.