juju: github.com/jimmiebtlr/juju/state/apiserver/charmrevisionupdater/testing Index | Files

package testing

import "github.com/jimmiebtlr/juju/state/apiserver/charmrevisionupdater/testing"

Index

Package Files

suite.go

type CharmSuite Uses

type CharmSuite struct {
    Server *charmtesting.MockStore
    // contains filtered or unexported fields
}

CharmSuite provides infrastructure to set up and perform tests associated with charm versioning. A mock charm store is created using some known charms used for testing.

func (*CharmSuite) AddCharmWithRevision Uses

func (s *CharmSuite) AddCharmWithRevision(c *gc.C, charmName string, rev int) *state.Charm

AddCharmWithRevision adds a charm with the specified revision to state.

func (*CharmSuite) AddMachine Uses

func (s *CharmSuite) AddMachine(c *gc.C, machineId string, job state.MachineJob)

AddMachine adds a new machine to state.

func (*CharmSuite) AddService Uses

func (s *CharmSuite) AddService(c *gc.C, charmName, serviceName string, networks []string)

AddService adds a service for the specified charm to state.

func (*CharmSuite) AddUnit Uses

func (s *CharmSuite) AddUnit(c *gc.C, serviceName, machineId string)

AddUnit adds a new unit for service to the specified machine.

func (*CharmSuite) SetUnitRevision Uses

func (s *CharmSuite) SetUnitRevision(c *gc.C, unitName string, rev int)

SetUnitRevision sets the unit's charm to the specified revision.

func (*CharmSuite) SetUpSuite Uses

func (s *CharmSuite) SetUpSuite(c *gc.C, jcSuite *jujutesting.JujuConnSuite)

func (*CharmSuite) SetUpTest Uses

func (s *CharmSuite) SetUpTest(c *gc.C)

func (*CharmSuite) SetupScenario Uses

func (s *CharmSuite) SetupScenario(c *gc.C)

SetupScenario adds some machines and services to state. It assumes a state server machine has already been created.

func (*CharmSuite) TearDownSuite Uses

func (s *CharmSuite) TearDownSuite(c *gc.C)

func (*CharmSuite) TearDownTest Uses

func (s *CharmSuite) TearDownTest(c *gc.C)

func (*CharmSuite) UpdateStoreRevision Uses

func (s *CharmSuite) UpdateStoreRevision(ch string, rev int)

UpdateStoreRevision sets the revision of the specified charm to rev.

Package testing imports 7 packages (graph). Updated 2016-08-03. Refresh now. Tools for package owners.