CentOS 6 only has Python 2.6 available, on which the unit testing
frameworks do not expose a `.assertIn()` helper method. Instead, we can
use `.assertTrue(x in y)`.
Signed-off-by: Steve Kuznetsov <skuznets@redhat.com>
When tests fail, artifacts from that tests are necessary to properly
debug the failure and determine how to fix the test. This is impossible
when artifacts are immediately removed after the test is finished.
Instead, the tests should remove old artifacts before the test run
begins.
Signed-off-by: Steve Kuznetsov <skuznets@redhat.com>
When multiple tags exist for one version of a project, or when a version
is passed to `tito tag --use-version` that does not exactly correspond
with a tag in the repository's git history, the auto-generated release
is not guaranteed to monotonically increase. In order for users to
overcome this issue without building complicated logic into `tito`, it
is simpler to allow users to provide a literal release string to use.
Signed-off-by: Steve Kuznetsov <skuznets@redhat.com>
By using a user specific URL, multiple members of the same team can
submit Copr releases without having to share credentials to the SRPM
remote location. For example, each member of the team can set
COPR_REMOTE_LOCATION in .titorc to their <username>.fedorapeople.org
space.
3892359 changed builder args to always be arrays, so concatenation of
rpmbuild options with other strings then failed.
File "/usr/lib/python2.7/site-packages/tito/release/main.py", line 530, in _koji_release
builder.srpm(dist=disttag)
File "/usr/lib/python2.7/site-packages/tito/builder/main.py", line 210, in srpm
rpmbuild_options = self.rpmbuild_options + self._scl_to_rpmbuild_option()
TypeError: can only concatenate list (not "str") to list
Change builder args to be joined by a single space, allowing multiple
arguments to be passed in.
Instead of being a command line-only option, the string of extra rpmbuild
arguments can now be passed in via the general builder args mechanism, so it
can even be configured from releasers.conf.
Fixes#155
Fixes issue where just build srpm would be deleted as too old if
building for a newer looking disttag in mock. (i.e. f20 building for
f21)
Also generates more correct looking SRPMs in all cases.
* 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
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.
Older versions of git-annex don't support `git annex lock --force`, so peform
a version check and call without --force on these.
The EL6 Docker image is changed to one that contains locales, in order for
git-annex to run successfully.
Particularly useful when creating new projects and wanting to avoid
creating an initial tag, this allows `tito build --test --srpm` etc
to run without any tag.
With a general 'scl' builder option, a software collection name can be
specified irrespective of the releaser used. RsyncReleaser's own 'scl'
option has been deprecated in favour of using 'builder.scl' in
releasers.conf.
Avoids...
Traceback (most recent call last):
File "/home/sandbox/test/functional/build_gitannex_tests.py", line 87, in test_simple_build
self.assertEquals(1, len(builder.sources))
nose.proxy.TypeError: TypeError: object of type 'map' has no len()