提交 3d8b26e3 编写于 作者: W wangyong1995626wywz

Complete the isempty() interface missing from treemap

Description:
    Add a test case to test isempty interface in treemap
    #I53JVK:Complete the isempty() interface missing from treemap
Signed-off-by: Nwangyong1995626wywz <wangyong237@huawei.com>
上级 99dd7ae8
......@@ -377,4 +377,17 @@ describe("TreeMapTest", function () {
}
expect(flag).assertEqual(true);
});
it("SR000GGR3H_testIsEmpty040", 0, function () {
let treeMap = new TreeMap();
treeMap.set(0, "a");
treeMap.set(1, "b");
treeMap.set(2, "c");
treeMap.set(3, "d");
treeMap.set(4, "g");
let res = treeMap.isEmpty();
expect(res).assertEqual(false);
treeMap.clear();
let res1 = treeMap.isEmpty();
expect(res1).assertEqual(true);
});
});
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册