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

Side by Side Diff: cmd/juju/deploy_test.go

Issue 93410043: Extract errors package to github.com/juju/errors
Patch Set: Created 9 years, 10 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 2012, 2013 Canonical Ltd. 1 // Copyright 2012, 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 main 4 package main
5 5
6 import ( 6 import (
7 "strings" 7 "strings"
8 8
9 "github.com/juju/errors"
9 jc "github.com/juju/testing/checkers" 10 jc "github.com/juju/testing/checkers"
10 gc "launchpad.net/gocheck" 11 gc "launchpad.net/gocheck"
11 12
12 "launchpad.net/juju-core/charm" 13 "launchpad.net/juju-core/charm"
13 "launchpad.net/juju-core/cmd/envcmd" 14 "launchpad.net/juju-core/cmd/envcmd"
14 "launchpad.net/juju-core/constraints" 15 "launchpad.net/juju-core/constraints"
15 "launchpad.net/juju-core/errors"
16 "launchpad.net/juju-core/instance" 16 "launchpad.net/juju-core/instance"
17 "launchpad.net/juju-core/juju/osenv" 17 "launchpad.net/juju-core/juju/osenv"
18 "launchpad.net/juju-core/juju/testing" 18 "launchpad.net/juju-core/juju/testing"
19 "launchpad.net/juju-core/state" 19 "launchpad.net/juju-core/state"
20 coretesting "launchpad.net/juju-core/testing" 20 coretesting "launchpad.net/juju-core/testing"
21 ) 21 )
22 22
23 type DeploySuite struct { 23 type DeploySuite struct {
24 testing.RepoSuite 24 testing.RepoSuite
25 } 25 }
(...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 262
263 func (s *DeploySuite) TestForceMachineSubordinate(c *gc.C) { 263 func (s *DeploySuite) TestForceMachineSubordinate(c *gc.C) {
264 machine, err := s.State.AddMachine("precise", state.JobHostUnits) 264 machine, err := s.State.AddMachine("precise", state.JobHostUnits)
265 c.Assert(err, gc.IsNil) 265 c.Assert(err, gc.IsNil)
266 coretesting.Charms.BundlePath(s.SeriesPath, "logging") 266 coretesting.Charms.BundlePath(s.SeriesPath, "logging")
267 err = runDeploy(c, "--to", machine.Id(), "local:logging") 267 err = runDeploy(c, "--to", machine.Id(), "local:logging")
268 c.Assert(err, gc.ErrorMatches, "cannot use --num-units or --to with subo rdinate service") 268 c.Assert(err, gc.ErrorMatches, "cannot use --num-units or --to with subo rdinate service")
269 _, err = s.State.Service("dummy") 269 _, err = s.State.Service("dummy")
270 c.Assert(err, gc.ErrorMatches, `service "dummy" not found`) 270 c.Assert(err, gc.ErrorMatches, `service "dummy" not found`)
271 } 271 }
OLDNEW

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