Merge lp:~canonical-ci-engineering/adt-request-proxy/trunk-add-series-passthrough into lp:adt-request-proxy

Proposed by Thomi Richards
Status: Merged
Approved by: Thomi Richards
Approved revision: 5
Merged at revision: 5
Proposed branch: lp:~canonical-ci-engineering/adt-request-proxy/trunk-add-series-passthrough
Merge into: lp:adt-request-proxy
Diff against target: 53 lines (+5/-6)
2 files modified
adt_request_proxy/tests/test_functional.py (+3/-2)
adt_request_proxy/v1.py (+2/-4)
To merge this branch: bzr merge lp:~canonical-ci-engineering/adt-request-proxy/trunk-add-series-passthrough
Reviewer Review Type Date Requested Status
Francis Ginther Approve
Review via email: mp+252531@code.launchpad.net

Commit message

Pass the 'series' form parameter through to the amqp payload.

Description of the change

Pass the 'series' form parameter through to the amqp payload.

To post a comment you must log in.
Revision history for this message
Francis Ginther (fginther) wrote :

looks sane.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'adt_request_proxy/tests/test_functional.py'
2--- adt_request_proxy/tests/test_functional.py 2015-03-11 01:36:47 +0000
3+++ adt_request_proxy/tests/test_functional.py 2015-03-11 02:46:39 +0000
4@@ -106,6 +106,7 @@
5 'package-name': 'librepng',
6 'architecture': 'i386',
7 'platform': 'nova',
8+ 'series': 'trusty',
9 }
10 )
11 self.assertThat(resp.status_code, Equals(200))
12@@ -160,7 +161,7 @@
13 'package_name': 'librepng',
14 'arch': 'amd64',
15 'platform': 'nova',
16- 'nova_image': 'some-nova-image',
17+ 'series': 'trusty',
18 }
19 copy_payload = test_payload.copy()
20 request_id = q.queue_test(copy_payload)
21@@ -173,7 +174,7 @@
22 'package_name': 'librepng',
23 'arch': 'amd64',
24 'platform': 'nova',
25- 'nova_image': 'some-nova-image',
26+ 'series': 'trusty',
27 }
28 request_id = q.queue_test(test_payload)
29
30
31=== modified file 'adt_request_proxy/v1.py'
32--- adt_request_proxy/v1.py 2015-03-10 20:41:29 +0000
33+++ adt_request_proxy/v1.py 2015-03-11 02:46:39 +0000
34@@ -28,6 +28,7 @@
35 'package-name',
36 'architecture',
37 'platform',
38+ 'series',
39 }
40 missing = required_keys.difference(set(request.form.keys()))
41 if missing:
42@@ -39,10 +40,7 @@
43 rabbit_request['apt_pocket'] = request.form.get('apt-pocket')
44 rabbit_request['arch'] = arch = request.form['architecture']
45 rabbit_request['platform'] = request.form['platform']
46- rabbit_request['nova_image'] = (
47- 'ubuntu-released/ubuntu-trusty-14.04-{}'
48- '-server-20150209.1-disk1.img'.format(arch)
49- )
50+ rabbit_request['series'] = request.form['series']
51
52 req_id = current_app.extensions['rabbit'].queue_test(rabbit_request)
53 return jsonify(

Subscribers

People subscribed via source and target branches

to all changes: