~juju-qa/ubuntu/xenial/juju/2.0-rc2

« back to all changes in this revision

Viewing changes to src/github.com/juju/juju/cmd/juju/block/list_test.go

  • Committer: Nicholas Skaggs
  • Date: 2016-09-30 14:39:30 UTC
  • mfrom: (1.8.1)
  • Revision ID: nicholas.skaggs@canonical.com-20160930143930-vwwhrefh6ftckccy
import upstream

Show diffs side-by-side

added added

removed removed

Lines of Context:
32
32
func (s *listCommandSuite) TestListEmpty(c *gc.C) {
33
33
        ctx, err := testing.RunCommand(c, block.NewListCommandForTest(&mockListClient{}, nil))
34
34
        c.Assert(err, jc.ErrorIsNil)
35
 
        c.Assert(testing.Stdout(ctx), gc.Equals, "No commands are currently disabled.\n")
 
35
        c.Assert(testing.Stderr(ctx), gc.Equals, "No commands are currently disabled.\n")
36
36
}
37
37
 
38
38
func (s *listCommandSuite) TestListError(c *gc.C) {
98
98
        )
99
99
}
100
100
 
 
101
func (s *listCommandSuite) TestListJSONEmpty(c *gc.C) {
 
102
        ctx, err := testing.RunCommand(c, block.NewListCommandForTest(&mockListClient{}, nil), "--format", "json")
 
103
        c.Assert(err, jc.ErrorIsNil)
 
104
        c.Assert(testing.Stdout(ctx), gc.Equals, "[]\n")
 
105
}
 
106
 
101
107
func (s *listCommandSuite) TestListJSON(c *gc.C) {
102
108
        cmd := block.NewListCommandForTest(s.mock(), nil)
103
109
        ctx, err := testing.RunCommand(c, cmd, "--format", "json")