mirror of
https://github.com/apache/rocketmq-dashboard.git
synced 2026-02-20 12:07:10 +08:00
Co-authored-by: zhangjidi <zhangjidi@cmss.chinamobile.com>
This commit is contained in:
@@ -92,7 +92,7 @@ public class ConsumerControllerTest extends BaseControllerTest {
|
||||
requestBuilder = MockMvcRequestBuilders.get(url);
|
||||
perform = mockMvc.perform(requestBuilder);
|
||||
perform.andExpect(status().isOk())
|
||||
.andExpect(jsonPath("$.data", hasSize(1)))
|
||||
.andExpect(jsonPath("$.data", hasSize(2)))
|
||||
.andExpect(jsonPath("$.data[0].group").value("group_test"))
|
||||
.andExpect(jsonPath("$.data[0].consumeType").value(ConsumeType.CONSUME_ACTIVELY.name()))
|
||||
.andExpect(jsonPath("$.data[0].messageModel").value(MessageModel.CLUSTERING.name()));
|
||||
|
||||
@@ -135,10 +135,13 @@ public class MockObjectUtil {
|
||||
|
||||
public static SubscriptionGroupWrapper createSubscriptionGroupWrapper() {
|
||||
SubscriptionGroupWrapper wrapper = new SubscriptionGroupWrapper();
|
||||
ConcurrentMap<String, SubscriptionGroupConfig> subscriptionGroupTable = new ConcurrentHashMap(2);
|
||||
SubscriptionGroupConfig config = new SubscriptionGroupConfig();
|
||||
config.setGroupName("group_test");
|
||||
ConcurrentMap<String, SubscriptionGroupConfig> subscriptionGroupTable = new ConcurrentHashMap(2);
|
||||
subscriptionGroupTable.put("group_test", config);
|
||||
SubscriptionGroupConfig sysGroupConfig = new SubscriptionGroupConfig();
|
||||
sysGroupConfig.setGroupName(MixAll.TOOLS_CONSUMER_GROUP);
|
||||
subscriptionGroupTable.put(MixAll.TOOLS_CONSUMER_GROUP, sysGroupConfig);
|
||||
wrapper.setSubscriptionGroupTable(subscriptionGroupTable);
|
||||
wrapper.setDataVersion(new DataVersion());
|
||||
return wrapper;
|
||||
|
||||
Reference in New Issue
Block a user