add errcode func

This commit is contained in:
张开元
2024-12-19 20:26:39 +08:00
parent dcd252f802
commit ed8fdebc81
2 changed files with 19 additions and 0 deletions

View File

@@ -10,3 +10,9 @@ func TestGetErrorCode(t *testing.T) {
code := GetErrorCode(err)
fmt.Println(code)
}
func TestGetErrorByCode(t *testing.T) {
code := 0
err := GetErrorByCode(code)
fmt.Println("[TestGetErrorByCode]:err:",err)
}