Merge lp:~didrocks/britney/additional-parameters into lp:~ubuntu-release/britney/britney2-ubuntu

Proposed by Didier Roche
Status: Merged
Merged at revision: 560
Proposed branch: lp:~didrocks/britney/additional-parameters
Merge into: lp:~ubuntu-release/britney/britney2-ubuntu
Diff against target: 42 lines (+25/-0)
1 file modified
run-autopkgtest (+25/-0)
To merge this branch: bzr merge lp:~didrocks/britney/additional-parameters
Reviewer Review Type Date Requested Status
Martin Pitt (community) Approve
Review via email: mp+282015@code.launchpad.net

Commit message

Add new env, test-git and test-bzr parameters to run-autopkgtest

To post a comment you must log in.
Revision history for this message
Martin Pitt (pitti) wrote :

Thanks!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'run-autopkgtest'
2--- run-autopkgtest 2015-11-27 07:16:55 +0000
3+++ run-autopkgtest 2016-01-08 15:04:29 +0000
4@@ -32,6 +32,25 @@
5 default=[],
6 help='Enable PPA for requested test(s). '
7 'Can be specified multiple times.')
8+ parser.add_argument('--env', metavar='KEY=VALUE', action='append',
9+ default=[],
10+ help='List of VAR=value strings. '
11+ 'This can be used to influence a test\'s behaviour '
12+ 'from a test request. '
13+ 'Can be specified multiple times.')
14+ parser.add_argument('--test-git',
15+ help='A single URL or URL branchname. '
16+ 'The test will be git cloned from that URL and ran '
17+ 'from the checkout. This will not build binary '
18+ 'packages from the branch and run tests against '
19+ 'those, the test dependencies will be taken from the '
20+ 'archive, or PPA if given. In this case the '
21+ 'srcpkgname will only be used for the result path in '
22+ 'swift and be irrelevant for the actual test.')
23+ parser.add_argument('--test-bzr',
24+ help='A single URL. '
25+ 'The test will be checked out with bzr from that URL. '
26+ 'Otherwise this has the same behaviour as test-git.')
27 parser.add_argument('package', nargs='+',
28 help='Source package name(s) whose tests to run.')
29 args = parser.parse_args()
30@@ -79,6 +98,12 @@
31 params['triggers'] = args.trigger
32 if args.ppa:
33 params['ppas'] = args.ppa
34+ if args.env:
35+ params['env'] = args.env
36+ if args.test_git:
37+ params['test-git'] = args.test_git
38+ if args.test_bzr:
39+ params['test-bzr'] = args.test_bzr
40 params = '\n' + json.dumps(params)
41
42 creds = urllib.parse.urlsplit(config.adt_amqp, allow_fragments=False)

Subscribers

People subscribed via source and target branches