worker/peergrouper: test failure

Bug #1299958 reported by Dave Cheney
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
juju-core
Fix Released
High
Dave Cheney

Bug Description

Replica sets are, well, sets, not lists. The tests should use jc.SameContent

[LOG] 0:00.003 INFO juju.worker.peergrouper successfully changed replica set to []replicaset.Member{replicaset.Member{Id:0, Address:"0.1.2.10:1234", Arbiter:(*bool)(nil), BuildIndexes:(*bool)(nil), Hidden:(*bool)(nil), Priority:(*float64)(nil), Tags:map[string]string{"juju-machine-id":"10"}, SlaveDelay:(*time.Duration)(nil), Votes:(*int)(nil)}, replicaset.Member{Id:1, Address:"0.1.2.11:1234", Arbiter:(*bool)(nil), BuildIndexes:(*bool)(nil), Hidden:(*bool)(nil), Priority:(*float64)(0xc2084af3b8), Tags:map[string]string{"juju-machine-id":"11"}, SlaveDelay:(*time.Duration)(nil), Votes:(*int)(0xc2084af3b0)}, replicaset.Member{Id:2, Address:"0.1.2.12:1234", Arbiter:(*bool)(nil), BuildIndexes:(*bool)(nil), Hidden:(*bool)(nil), Priority:(*float64)(0xc2084af3e0), Tags:map[string]string{"juju-machine-id":"12"}, SlaveDelay:(*time.Duration)(nil), Votes:(*int)(0xc2084af3c8)}}
worker_test.go:382:
    c.Assert(instanceIds, jc.DeepEquals, []instance.Id{"id-10", "id-11", "id-12"})
... obtained []instance.Id = []instance.Id{"id-12", "id-10", "id-11"}
... expected []instance.Id = []instance.Id{"id-10", "id-11", "id-12"}
... mismatch at [0]: unequal; obtained "id-12"; expected "id-10"

[LOG] 0:00.010 ERROR juju.worker.peergrouper peergrouper loop terminated: tomb: dying
OOPS: 9 passed, 2 FAILED
--- FAIL: TestPackage (1.14 seconds)
FAIL
FAIL launchpad.net/juju-core/worker/peergrouper 1.236s

Tags: ppc64el

Related branches

Revision history for this message
Dave Cheney (dave-cheney) wrote :

worker_test.go:350:
    c.Assert(servers, jc.DeepEquals, expectedAPIHostPorts(3))
... obtained [][]instance.HostPort = [][]instance.HostPort{[]instance.HostPort{instance.HostPort{Address:instance.Address{Value:"0.1.2.11", Type:"ipv4", NetworkName:"", NetworkScope:""}, Port:5678}}, []instance.HostPort{instance.HostPort{Address:instance.Address{Value:"0.1.2.12", Type:"ipv4", NetworkName:"", NetworkScope:""}, Port:5678}}, []instance.HostPort{instance.HostPort{Address:instance.Address{Value:"0.1.2.10", Type:"ipv4", NetworkName:"", NetworkScope:""}, Port:5678}}}
... expected [][]instance.HostPort = [][]instance.HostPort{[]instance.HostPort{instance.HostPort{Address:instance.Address{Value:"0.1.2.10", Type:"ipv4", NetworkName:"", NetworkScope:""}, Port:5678}}, []instance.HostPort{instance.HostPort{Address:instance.Address{Value:"0.1.2.11", Type:"ipv4", NetworkName:"", NetworkScope:""}, Port:5678}}, []instance.HostPort{instance.HostPort{Address:instance.Address{Value:"0.1.2.12", Type:"ipv4", NetworkName:"", NetworkScope:""}, Port:5678}}}
... mismatch at [0][0].Address.Value: unequal; obtained "0.1.2.11"; expected "0.1.2.10"

[LOG] 0:00.023 ERROR juju.worker.peergrouper peergrouper loop terminated: tomb: dying

Changed in juju-core:
assignee: nobody → Dave Cheney (dave-cheney)
Changed in juju-core:
milestone: 1.18.0 → changelog.txt
status: Triaged → In Progress
milestone: changelog.txt → 1.18.0
Changed in juju-core:
milestone: 1.19.0 → 2.0
Changed in juju-core:
status: In Progress → Fix Committed
milestone: 2.0 → 1.19.0
Curtis Hovey (sinzui)
Changed in juju-core:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.