Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(243)

Side by Side Diff: provider/local/environ_test.go

Issue 49640050: provider/local: always use filestorage on CLI
Patch Set: provider/local: always use filestorage on CLI Created 11 years, 2 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2013 Canonical Ltd. 1 // Copyright 2013 Canonical Ltd.
2 // Licensed under the AGPLv3, see LICENCE file for details. 2 // Licensed under the AGPLv3, see LICENCE file for details.
3 3
4 package local_test 4 package local_test
5 5
6 import ( 6 import (
7 "io/ioutil" 7 "io/ioutil"
8 "os" 8 "os"
9 "path/filepath" 9 "path/filepath"
10 "strings" 10 "strings"
(...skipping 19 matching lines...) Expand all
30 envtesting.ToolsFixture 30 envtesting.ToolsFixture
31 } 31 }
32 32
33 var _ = gc.Suite(&environSuite{}) 33 var _ = gc.Suite(&environSuite{})
34 34
35 func (s *environSuite) SetUpTest(c *gc.C) { 35 func (s *environSuite) SetUpTest(c *gc.C) {
36 s.baseProviderSuite.SetUpTest(c) 36 s.baseProviderSuite.SetUpTest(c)
37 s.ToolsFixture.SetUpTest(c) 37 s.ToolsFixture.SetUpTest(c)
38 } 38 }
39 39
40 func (s *environSuite) TearDownTest(c *gc.C) {
41 s.ToolsFixture.TearDownTest(c)
42 s.baseProviderSuite.TearDownTest(c)
43 }
44
40 func (*environSuite) TestOpenFailsWithProtectedDirectories(c *gc.C) { 45 func (*environSuite) TestOpenFailsWithProtectedDirectories(c *gc.C) {
41 testConfig := minimalConfig(c) 46 testConfig := minimalConfig(c)
42 testConfig, err := testConfig.Apply(map[string]interface{}{ 47 testConfig, err := testConfig.Apply(map[string]interface{}{
43 "root-dir": "/usr/lib/juju", 48 "root-dir": "/usr/lib/juju",
44 }) 49 })
45 c.Assert(err, gc.IsNil) 50 c.Assert(err, gc.IsNil)
46 51
47 environ, err := local.Provider.Open(testConfig) 52 environ, err := local.Provider.Open(testConfig)
48 c.Assert(err, gc.ErrorMatches, "mkdir .* permission denied") 53 c.Assert(err, gc.ErrorMatches, "mkdir .* permission denied")
49 c.Assert(environ, gc.IsNil) 54 c.Assert(environ, gc.IsNil)
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 envtesting.UploadFakeTools(c, environ.Storage()) 159 envtesting.UploadFakeTools(c, environ.Storage())
155 defer environ.Storage().RemoveAll() 160 defer environ.Storage().RemoveAll()
156 ctx := envtesting.NewBootstrapContext(coretesting.Context(c)) 161 ctx := envtesting.NewBootstrapContext(coretesting.Context(c))
157 err = environ.Bootstrap(ctx, constraints.Value{}) 162 err = environ.Bootstrap(ctx, constraints.Value{})
158 c.Assert(err, gc.IsNil) 163 c.Assert(err, gc.IsNil)
159 } 164 }
160 165
161 func (s *localJujuTestSuite) TestStartStop(c *gc.C) { 166 func (s *localJujuTestSuite) TestStartStop(c *gc.C) {
162 c.Skip("StartInstance not implemented yet.") 167 c.Skip("StartInstance not implemented yet.")
163 } 168 }
OLDNEW

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b