Browse Source

fix test

mq-subscribe
chrislu 8 months ago
parent
commit
b166597c83
  1. 1
      weed/mq/pub_balancer/allocate_test.go
  2. 2
      weed/mq/pub_balancer/balance_brokers_test.go

1
weed/mq/pub_balancer/allocate_test.go

@ -12,7 +12,6 @@ func Test_allocateOneBroker(t *testing.T) {
brokers := cmap.New[*BrokerStats]()
brokers.SetIfAbsent("localhost:17777", &BrokerStats{
TopicPartitionCount: 0,
ConsumerCount: 0,
CpuUsagePercent: 0,
})

2
weed/mq/pub_balancer/balance_brokers_test.go

@ -12,7 +12,6 @@ func TestBalanceTopicPartitionOnBrokers(t *testing.T) {
brokers := cmap.New[*BrokerStats]()
broker1Stats := &BrokerStats{
TopicPartitionCount: 1,
ConsumerCount: 1,
CpuUsagePercent: 1,
TopicPartitionStats: cmap.New[*TopicPartitionStats](),
}
@ -24,7 +23,6 @@ func TestBalanceTopicPartitionOnBrokers(t *testing.T) {
})
broker2Stats := &BrokerStats{
TopicPartitionCount: 2,
ConsumerCount: 1,
CpuUsagePercent: 1,
TopicPartitionStats: cmap.New[*TopicPartitionStats](),
}

Loading…
Cancel
Save