baerwang commented on code in PR #658:
URL: https://github.com/apache/dubbo-go-pixiu/pull/658#discussion_r2066297497
##########
pkg/common/router/trie/trie_test.go:
##########
@@ -210,23 +210,29 @@ func TestTrie_ParamMatch(t *testing.T) {
func TestTrieSoftDelete(t *testing.T) {
trie := NewTrie()
- trie.Put("/a/b/c", "route1")
- trie.Put("/a/b/c/d", "route2")
- trie.Put("/a/b/e", "route3")
+ ret, _ := trie.Put("/a/b/c", "route1")
+ assert.True(t, ret)
+
+ ret, _ = trie.Put("/a/b/c/d", "route2")
+ assert.True(t, ret)
+
+ ret, _ = trie.Put("/a/b/e", "route3")
+ assert.True(t, ret)
node, _, ok := trie.Match("/a/b/c")
assert.True(t, ok)
assert.Equal(t, "route1", node.GetBizInfo())
- trie.Remove("/a/b/c")
+ node, _ = trie.Remove("/a/b/c")
+ assert.True(t, ret)
Review Comment:
这有点问题吧
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]