Merge lp:~waigani/juju-core/1299969-isolate-more-ssh-tests into lp:~go-bot/juju-core/trunk

Proposed by Jesse Meek
Status: Merged
Approved by: Jesse Meek
Approved revision: no longer in the source branch.
Merged at revision: 2616
Proposed branch: lp:~waigani/juju-core/1299969-isolate-more-ssh-tests
Merge into: lp:~go-bot/juju-core/trunk
Diff against target: 45 lines (+4/-5)
2 files modified
provider/common/bootstrap_test.go (+2/-3)
provider/common/supportedarchitectures_test.go (+2/-2)
To merge this branch: bzr merge lp:~waigani/juju-core/1299969-isolate-more-ssh-tests
Reviewer Review Type Date Requested Status
Juju Engineering Pending
Review via email: mp+215382@code.launchpad.net

Commit message

Isolate ssh tests with FakeHomeSuite

Use the FakeHomeSuite to isolate
provider/common tests which require
ssh keys.

Description of the change

Isolate ssh tests with FakeHomeSuite

Use the FakeHomeSuite to isolate
provider/common tests which require
ssh keys.

https://codereview.appspot.com/86800043/

To post a comment you must log in.
Revision history for this message
Jesse Meek (waigani) wrote :

Reviewers: mp+215382_code.launchpad.net,

Message:
Please take a look.

Description:
Isolate ssh tests with FakeHomeSuite

Use the FakeHomeSuite to isolate
provider/common tests which require
ssh keys.

https://code.launchpad.net/~waigani/juju-core/1299969-isolate-more-ssh-tests/+merge/215382

(do not edit description out of merge proposal)

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

Affected files (+6, -5 lines):
   A [revision details]
   M provider/common/bootstrap_test.go
   M provider/common/supportedarchitectures_test.go

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: tarmac-20140411070034-bz7mjvbtc6wieyy8
+New revision: <email address hidden>

Index: provider/common/bootstrap_test.go
=== modified file 'provider/common/bootstrap_test.go'
--- provider/common/bootstrap_test.go 2014-04-04 15:55:19 +0000
+++ provider/common/bootstrap_test.go 2014-04-11 10:12:20 +0000
@@ -22,13 +22,12 @@
   "launchpad.net/juju-core/instance"
   "launchpad.net/juju-core/provider/common"
   coretesting "launchpad.net/juju-core/testing"
- "launchpad.net/juju-core/testing/testbase"
   "launchpad.net/juju-core/tools"
   "launchpad.net/juju-core/utils/ssh"
  )

  type BootstrapSuite struct {
- testbase.LoggingSuite
+ coretesting.FakeHomeSuite
   envtesting.ToolsFixture
  }

@@ -39,7 +38,7 @@
  }

  func (s *BootstrapSuite) SetUpTest(c *gc.C) {
- s.LoggingSuite.SetUpTest(c)
+ s.FakeHomeSuite.SetUpTest(c)
   s.ToolsFixture.SetUpTest(c)
   s.PatchValue(common.ConnectSSH, func(_ ssh.Client, host, checkHostScript
string) error {
    return fmt.Errorf("mock connection failure to %s", host)

Index: provider/common/supportedarchitectures_test.go
=== modified file 'provider/common/supportedarchitectures_test.go'
--- provider/common/supportedarchitectures_test.go 2014-04-10 05:25:17 +0000
+++ provider/common/supportedarchitectures_test.go 2014-04-11 10:12:20 +0000
@@ -12,11 +12,11 @@
   "launchpad.net/juju-core/environs/imagemetadata"
   "launchpad.net/juju-core/environs/simplestreams"
   "launchpad.net/juju-core/provider/common"
- "launchpad.net/juju-core/testing/testbase"
+ coretesting "launchpad.net/juju-core/testing"
  )

  type archSuite struct {
- testbase.LoggingSuite
+ coretesting.FakeHomeSuite
  }

  var _ = gc.Suite(&archSuite{})

Revision history for this message
Dave Cheney (dave-cheney) wrote :

LGTM. Ship it

$ go test ./provider/common/
ok launchpad.net/juju-core/provider/common 24.926s

https://codereview.appspot.com/86800043/

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'provider/common/bootstrap_test.go'
2--- provider/common/bootstrap_test.go 2014-04-04 15:55:19 +0000
3+++ provider/common/bootstrap_test.go 2014-04-11 10:15:17 +0000
4@@ -22,13 +22,12 @@
5 "launchpad.net/juju-core/instance"
6 "launchpad.net/juju-core/provider/common"
7 coretesting "launchpad.net/juju-core/testing"
8- "launchpad.net/juju-core/testing/testbase"
9 "launchpad.net/juju-core/tools"
10 "launchpad.net/juju-core/utils/ssh"
11 )
12
13 type BootstrapSuite struct {
14- testbase.LoggingSuite
15+ coretesting.FakeHomeSuite
16 envtesting.ToolsFixture
17 }
18
19@@ -39,7 +38,7 @@
20 }
21
22 func (s *BootstrapSuite) SetUpTest(c *gc.C) {
23- s.LoggingSuite.SetUpTest(c)
24+ s.FakeHomeSuite.SetUpTest(c)
25 s.ToolsFixture.SetUpTest(c)
26 s.PatchValue(common.ConnectSSH, func(_ ssh.Client, host, checkHostScript string) error {
27 return fmt.Errorf("mock connection failure to %s", host)
28
29=== modified file 'provider/common/supportedarchitectures_test.go'
30--- provider/common/supportedarchitectures_test.go 2014-04-10 05:25:17 +0000
31+++ provider/common/supportedarchitectures_test.go 2014-04-11 10:15:17 +0000
32@@ -12,11 +12,11 @@
33 "launchpad.net/juju-core/environs/imagemetadata"
34 "launchpad.net/juju-core/environs/simplestreams"
35 "launchpad.net/juju-core/provider/common"
36- "launchpad.net/juju-core/testing/testbase"
37+ coretesting "launchpad.net/juju-core/testing"
38 )
39
40 type archSuite struct {
41- testbase.LoggingSuite
42+ coretesting.FakeHomeSuite
43 }
44
45 var _ = gc.Suite(&archSuite{})

Subscribers

People subscribed via source and target branches

to status/vote changes: