You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by hu...@apache.org on 2022/03/29 04:32:09 UTC
[rocketmq-mqtt] 41/43: increase code coverage
This is an automated email from the ASF dual-hosted git repository.
huzongtang pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/rocketmq-mqtt.git
commit 0b20ee717dd91ba3bc829c3f57c7ee6eafa4c439
Author: shendongsd <sh...@cmss.chinamobile.com>
AuthorDate: Tue Mar 22 15:37:55 2022 +0800
increase code coverage
---
.../rocketmq/mqtt/common/test/TestMessageUtil.java | 19 +++++++++++++++++--
.../rocketmq/mqtt/common/test/TestNamespaceUtil.java | 2 --
2 files changed, 17 insertions(+), 4 deletions(-)
diff --git a/mqtt-common/src/test/java/org/apache/rocketmq/mqtt/common/test/TestMessageUtil.java b/mqtt-common/src/test/java/org/apache/rocketmq/mqtt/common/test/TestMessageUtil.java
index f5f93dd..abce8e9 100644
--- a/mqtt-common/src/test/java/org/apache/rocketmq/mqtt/common/test/TestMessageUtil.java
+++ b/mqtt-common/src/test/java/org/apache/rocketmq/mqtt/common/test/TestMessageUtil.java
@@ -1,13 +1,28 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
package org.apache.rocketmq.mqtt.common.test;
import io.netty.buffer.ByteBuf;
import io.netty.buffer.ByteBufAllocator;
-import io.netty.buffer.Unpooled;
import io.netty.buffer.UnpooledByteBufAllocator;
import io.netty.handler.codec.mqtt.*;
import org.apache.rocketmq.mqtt.common.model.Message;
import org.apache.rocketmq.mqtt.common.util.MessageUtil;
-import org.apache.rocketmq.mqtt.common.util.TopicUtils;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;
diff --git a/mqtt-common/src/test/java/org/apache/rocketmq/mqtt/common/test/TestNamespaceUtil.java b/mqtt-common/src/test/java/org/apache/rocketmq/mqtt/common/test/TestNamespaceUtil.java
index e80bb6d..5b38e22 100644
--- a/mqtt-common/src/test/java/org/apache/rocketmq/mqtt/common/test/TestNamespaceUtil.java
+++ b/mqtt-common/src/test/java/org/apache/rocketmq/mqtt/common/test/TestNamespaceUtil.java
@@ -19,8 +19,6 @@
package org.apache.rocketmq.mqtt.common.test;
-import org.apache.commons.collections.CollectionUtils;
-import org.apache.rocketmq.mqtt.common.model.Trie;
import org.apache.rocketmq.mqtt.common.util.NamespaceUtil;
import org.junit.Assert;
import org.junit.Before;