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

Delta Between Two Patch Sets: juju/jujutest/startstop.go

Issue 5432056: Skeleton framework for ec2 provider.
Left Patch Set: - Created 12 years, 4 months ago
Right Patch Set: - Created 12 years, 3 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:
Right: Side by side diff | Download
« no previous file with change/comment | « juju/jujutest/Makefile ('k') | juju/jujutest/test.go » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
(no file at all)
1 package jujutest
2
3 import (
4 . "launchpad.net/gocheck"
5 "launchpad.net/juju/go/juju"
6 )
7
8 func (t *Tests) TestStartStop(c *C) {
9 e, err := t.Environs.Open(t.Name)
10 c.Assert(err, IsNil)
11 c.Assert(e, NotNil)
12
13 err = e.Bootstrap()
14 c.Assert(err, IsNil)
15
16 t.addEnviron(e)
17
18 is, err := e.Instances()
19 c.Assert(err, IsNil)
20 c.Assert(len(is), Equals, 0)
21
22 m, err := e.StartInstance(0)
23 c.Assert(err, IsNil)
24 c.Assert(m, NotNil)
25 id0 := m.Id()
26
27 is, err = e.Instances()
28 c.Assert(err, IsNil)
29 c.Assert(len(is), Equals, 1)
30 c.Assert(m.Id(), Equals, id0)
31
32 err = e.StopInstances([]juju.Instance{m})
33 c.Assert(err, IsNil)
34 }
LEFTRIGHT

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