Merge lp:~lazypower/charms/precise/mediawiki/ci-fix into lp:charms/mediawiki

Proposed by Charles Butler
Status: Merged
Merged at revision: 77
Proposed branch: lp:~lazypower/charms/precise/mediawiki/ci-fix
Merge into: lp:charms/mediawiki
Diff against target: 62 lines (+17/-14)
4 files modified
.bzrignore (+3/-0)
tests/00-setup (+10/-0)
tests/00_setup.sh (+0/-10)
tests/100-deploy (+4/-4)
To merge this branch: bzr merge lp:~lazypower/charms/precise/mediawiki/ci-fix
Reviewer Review Type Date Requested Status
charmers Pending
Review via email: mp+207761@code.launchpad.net

Description of the change

Moved test files around to mimic charm add tests

This setup has been tested and validated against a clean juju host running
through vagrant. All dependencies are met, test files are executing and
returning positive results

2014-02-22 00:08:54 Deployment complete in 353.25 seconds
juju-test.conductor.100-deploy RESULT : ✔
juju-test INFO : Results: 1 passed, 0 failed, 0 errored

https://codereview.appspot.com/67220043/

To post a comment you must log in.
Revision history for this message
Charles Butler (lazypower) wrote :
Download full text (3.3 KiB)

Reviewers: mp+207761_code.launchpad.net,

Message:
Please take a look.

Description:
Moved test files around to mimic charm add tests

This setup has been tested and validated against a clean juju host
running
through vagrant. All dependencies are met, test files are executing and
returning positive results

2014-02-22 00:08:54 Deployment complete in 353.25 seconds
juju-test.conductor.100-deploy RESULT : ✔
juju-test INFO : Results: 1 passed, 0 failed, 0 errored

https://code.launchpad.net/~lazypower/charms/precise/mediawiki/ci-fix/+merge/207761

(do not edit description out of merge proposal)

Please review this at https://codereview.appspot.com/67220043/

Affected files (+19, -14 lines):
   A .bzrignore
   A [revision details]
   A tests/00-setup
   D tests/00_setup.sh
   M tests/100-deploy

Index: .bzrignore
=== added file '.bzrignore'
--- .bzrignore 1970-01-01 00:00:00 +0000
+++ .bzrignore 2014-02-22 00:42:44 +0000
@@ -0,0 +1,3 @@
+.vagrant
+Vagrantfile
+juju-vagrant-setup.sh

Index: [revision details]
=== added file '[revision details]'
--- [revision details] 2012-01-01 00:00:00 +0000
+++ [revision details] 2012-01-01 00:00:00 +0000
@@ -0,0 +1,2 @@
+Old revision: <email address hidden>
+New revision: <email address hidden>

Index: tests/00-setup
=== added file 'tests/00-setup'
--- tests/00-setup 1970-01-01 00:00:00 +0000
+++ tests/00-setup 2014-02-21 23:29:26 +0000
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+#TODO: Some of the python3 packs may not be available in precise.
+
+sudo apt-get install python3-setuptools -y
+sudo apt-add-repository ppa:juju/stable -y
+sudo apt-get update
+
+sudo apt-get install amulet python3 python3-requests python3-dev
python3-pip phantomjs -y
+sudo pip3 install splinter selenium

Index: tests/00_setup.sh
=== removed file 'tests/00_setup.sh'
--- tests/00_setup.sh 2014-02-19 22:04:58 +0000
+++ tests/00_setup.sh 1970-01-01 00:00:00 +0000
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-#TODO: Some of the python3 packs may not be available in precise.
-
-sudo apt-get install python3-setuptools -y
-sudo apt-add-repository ppa:juju/stable -y
-sudo apt-get update
-
-sudo apt-get install amulet python3 python3-requests python3-dev
python3-pip phantomjs -y
-sudo pip3 install splinter selenium

Index: tests/100-deploy
=== modified file 'tests/100-deploy'
--- tests/100-deploy 2014-02-20 00:58:28 +0000
+++ tests/100-deploy 2014-02-21 23:29:26 +0000
@@ -69,16 +69,16 @@

  title = str(browser.title).find("Log in")
  if title == -1:
- amulet.raise_status(amulet.FAIL, msg="Failed login test.")
+ amulet.raise_status(amulet.FAIL, msg="Failed login test.")

  title = str(browser.title).find("amulet-wiki")
  if title == -1:
- amulet.raise_status(amulet.FAIL, msg="Failed to parse provided title")
+ amulet.raise_status(amulet.FAIL, msg="Failed to parse provided title")

  browser.fill("wpName", 'tom')
  browser.fill('wpPassword', 'swordfish')
  browser.find_by_id('wpLoginAttempt').first.click()

  if not browser.is_text_present('tom'):
- amulet.raise_status(amulet.FAIL,
- ...

Read more...

Revision history for this message
Marco Ceppi (marcoceppi) wrote :

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added file '.bzrignore'
2--- .bzrignore 1970-01-01 00:00:00 +0000
3+++ .bzrignore 2014-02-22 00:44:14 +0000
4@@ -0,0 +1,3 @@
5+.vagrant
6+Vagrantfile
7+juju-vagrant-setup.sh
8
9=== added file 'tests/00-setup'
10--- tests/00-setup 1970-01-01 00:00:00 +0000
11+++ tests/00-setup 2014-02-22 00:44:14 +0000
12@@ -0,0 +1,10 @@
13+#!/bin/bash
14+
15+#TODO: Some of the python3 packs may not be available in precise.
16+
17+sudo apt-get install python3-setuptools -y
18+sudo apt-add-repository ppa:juju/stable -y
19+sudo apt-get update
20+
21+sudo apt-get install amulet python3 python3-requests python3-dev python3-pip phantomjs -y
22+sudo pip3 install splinter selenium
23
24=== removed file 'tests/00_setup.sh'
25--- tests/00_setup.sh 2014-02-19 22:04:58 +0000
26+++ tests/00_setup.sh 1970-01-01 00:00:00 +0000
27@@ -1,10 +0,0 @@
28-#!/bin/bash
29-
30-#TODO: Some of the python3 packs may not be available in precise.
31-
32-sudo apt-get install python3-setuptools -y
33-sudo apt-add-repository ppa:juju/stable -y
34-sudo apt-get update
35-
36-sudo apt-get install amulet python3 python3-requests python3-dev python3-pip phantomjs -y
37-sudo pip3 install splinter selenium
38
39=== modified file 'tests/100-deploy'
40--- tests/100-deploy 2014-02-20 00:58:28 +0000
41+++ tests/100-deploy 2014-02-22 00:44:14 +0000
42@@ -69,16 +69,16 @@
43
44 title = str(browser.title).find("Log in")
45 if title == -1:
46- amulet.raise_status(amulet.FAIL, msg="Failed login test.")
47+ amulet.raise_status(amulet.FAIL, msg="Failed login test.")
48
49 title = str(browser.title).find("amulet-wiki")
50 if title == -1:
51- amulet.raise_status(amulet.FAIL, msg="Failed to parse provided title")
52+ amulet.raise_status(amulet.FAIL, msg="Failed to parse provided title")
53
54 browser.fill("wpName", 'tom')
55 browser.fill('wpPassword', 'swordfish')
56 browser.find_by_id('wpLoginAttempt').first.click()
57
58 if not browser.is_text_present('tom'):
59- amulet.raise_status(amulet.FAIL,
60- msg="Failed to login with configured admin")
61+ amulet.raise_status(amulet.FAIL,
62+ msg="Failed to login with configured admin")

Subscribers

People subscribed via source and target branches

to all changes: