Index: worker/uniter/charm/deployer_test.go |
=== modified file 'worker/uniter/charm/deployer_test.go' |
--- worker/uniter/charm/deployer_test.go 2012-09-06 08:16:19 +0000 |
+++ worker/uniter/charm/deployer_test.go 2012-09-11 15:34:31 +0000 |
@@ -27,7 +27,7 @@ |
err := ioutil.WriteFile(filepath.Join(path, "some-file"), []byte("hello"), 0644) |
c.Assert(err, IsNil) |
}) |
- err := d.SetCharm(bun, corecharm.MustParseURL("cs:s/c-1")) |
+ err := d.Stage(bun, corecharm.MustParseURL("cs:s/c-1")) |
c.Assert(err, IsNil) |
target := charm.NewGitDir(filepath.Join(c.MkDir(), "target")) |
err = d.Deploy(target) |
@@ -37,7 +37,7 @@ |
data, err := ioutil.ReadFile(filepath.Join(target.Path(), "some-file")) |
c.Assert(err, IsNil) |
c.Assert(string(data), Equals, "hello") |
- url, err := target.ReadCharmURL() |
+ url, err := charm.ReadCharmURL(target) |
c.Assert(err, IsNil) |
c.Assert(url, DeepEquals, corecharm.MustParseURL("cs:s/c-1")) |
lines, err := target.Log() |
@@ -54,7 +54,7 @@ |
err := ioutil.WriteFile(filepath.Join(path, "some-file"), []byte("hello"), 0644) |
c.Assert(err, IsNil) |
}) |
- err := d.SetCharm(bun1, corecharm.MustParseURL("cs:s/c-1")) |
+ err := d.Stage(bun1, corecharm.MustParseURL("cs:s/c-1")) |
c.Assert(err, IsNil) |
target := charm.NewGitDir(filepath.Join(c.MkDir(), "target")) |
err = d.Deploy(target) |
@@ -65,7 +65,7 @@ |
err := ioutil.WriteFile(filepath.Join(path, "some-file"), []byte("goodbye"), 0644) |
c.Assert(err, IsNil) |
}) |
- err = d.SetCharm(bun2, corecharm.MustParseURL("cs:s/c-2")) |
+ err = d.Stage(bun2, corecharm.MustParseURL("cs:s/c-2")) |
c.Assert(err, IsNil) |
err = d.Deploy(target) |
c.Assert(err, IsNil) |
@@ -74,7 +74,7 @@ |
data, err := ioutil.ReadFile(filepath.Join(target.Path(), "some-file")) |
c.Assert(err, IsNil) |
c.Assert(string(data), Equals, "goodbye") |
- url, err := target.ReadCharmURL() |
+ url, err := charm.ReadCharmURL(target) |
c.Assert(err, IsNil) |
c.Assert(url, DeepEquals, corecharm.MustParseURL("cs:s/c-2")) |
lines, err := target.Log() |
@@ -90,7 +90,7 @@ |
err := ioutil.WriteFile(filepath.Join(path, "some-file"), []byte("hello"), 0644) |
c.Assert(err, IsNil) |
}) |
- err := d.SetCharm(bun1, corecharm.MustParseURL("cs:s/c-1")) |
+ err := d.Stage(bun1, corecharm.MustParseURL("cs:s/c-1")) |
c.Assert(err, IsNil) |
target := charm.NewGitDir(filepath.Join(c.MkDir(), "target")) |
err = d.Deploy(target) |
@@ -105,7 +105,7 @@ |
err := ioutil.WriteFile(filepath.Join(path, "some-file"), []byte("goodbye"), 0644) |
c.Assert(err, IsNil) |
}) |
- err = d.SetCharm(bun2, corecharm.MustParseURL("cs:s/c-2")) |
+ err = d.Stage(bun2, corecharm.MustParseURL("cs:s/c-2")) |
c.Assert(err, IsNil) |
err = d.Deploy(target) |
c.Assert(err, Equals, charm.ErrConflict) |