Merge lp:~canonical-losas/charms/trusty/squid-reverseproxy/venv-testing into lp:charms/trusty/squid-reverseproxy

Proposed by Paul Collins
Status: Superseded
Proposed branch: lp:~canonical-losas/charms/trusty/squid-reverseproxy/venv-testing
Merge into: lp:charms/trusty/squid-reverseproxy
Diff against target: 39 lines (+11/-2)
2 files modified
Makefile (+10/-1)
hooks/install (+1/-1)
To merge this branch: bzr merge lp:~canonical-losas/charms/trusty/squid-reverseproxy/venv-testing
Reviewer Review Type Date Requested Status
charmers Pending
Review via email: mp+250572@code.launchpad.net

This proposal has been superseded by a proposal from 2015-02-23.

Description of the change

Address bug#1401323 by creating the virtualenv using --system-site-packages so that apt_pkg can be accessed.

To post a comment you must log in.
51. By Paul Collins

merge from trusty, resolving hooks/hooks.py conflict

Unmerged revisions

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'Makefile'
2--- Makefile 2014-10-31 15:05:23 +0000
3+++ Makefile 2015-02-23 02:11:13 +0000
4@@ -21,7 +21,7 @@
5 @(charm proof $(PWD) || [ $$? -eq 100 ]) && echo OK
6 @test `cat revision` = 0 && rm revision
7
8-test:
9+test: .venv
10 @echo Starting tests...
11 @pip install nose testtools mock pyyaml
12 @CHARM_DIR=$(CHARM_DIR) $(TEST_PREFIX) nosetests -s $(TEST_DIR)
13@@ -41,4 +41,13 @@
14 -d hooks/charmhelpers
15 @echo Do not forget to commit the updated files if any.
16
17+.venv:
18+ sudo apt-get install -y python-pip python-coverage python-nose python-testtools \
19+ python-mock make bzr python-virtualenv
20+ virtualenv .venv --system-site-packages
21+
22+clean:
23+ rm -rf .venv
24+
25+
26 .PHONY: revision proof test lint sourcedeps charm-payload
27
28=== modified file 'hooks/install'
29--- hooks/install 2013-10-10 22:50:35 +0000
30+++ hooks/install 2015-02-23 02:11:13 +0000
31@@ -3,7 +3,7 @@
32 set -eu
33
34 juju-log 'Invoking charm-pre-install hooks'
35-[ -d exec.d ] && ( for f in exec.d/*/charm-pre-install; do [ -x $f ] && /bin/sh -c "$f"; done )
36+[ -d exec.d ] && ( for f in exec.d/*/charm-pre-install; do [ -x $f ] && /bin/sh -c "$f"; done ) || true
37
38 juju-log 'Invoking python-based install hook'
39 python hooks/hooks.py install

Subscribers

People subscribed via source and target branches