コード例 #1
0
ファイル: address_test.go プロジェクト: klyachin/juju
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
ファイル: address_test.go プロジェクト: klyachin/juju
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)
}