Files
seaweedfs/go/topology/topo_test.go

18 lines
298 B
Go
Raw Normal View History

2012-08-29 01:42:24 -07:00
package topology
import (
2012-08-31 01:35:11 -07:00
"testing"
2012-08-29 01:42:24 -07:00
)
func TestRemoveDataCenter(t *testing.T) {
topo := setup(topologyLayout)
topo.UnlinkChildNode(NodeId("dc2"))
if topo.GetActiveVolumeCount() != 15 {
2012-09-01 02:20:59 -07:00
t.Fail()
}
topo.UnlinkChildNode(NodeId("dc3"))
if topo.GetActiveVolumeCount() != 12 {
2012-09-01 02:20:59 -07:00
t.Fail()
}
}