示例#1
0
func (s *AddressSuite) TestInstanceAddressRoundtrips(c *gc.C) {
	instanceaddress := network.Address{"0.0.0.0", network.IPv4Address,
		"net", network.ScopeUnknown}
	stateaddress := state.NewAddress(instanceaddress)
	addr := stateaddress.InstanceAddress()
	c.Assert(addr, gc.Equals, instanceaddress)
}
示例#2
0
func (s *AddressSuite) TestNewAddress(c *gc.C) {
	instanceaddress := network.Address{"0.0.0.0", network.IPv4Address,
		"net", network.ScopeUnknown}
	stateaddress := state.NewAddress(instanceaddress)
	c.Assert(stateaddress, gc.NotNil)
}