test: add more tests (#1147)

* test: add more tests

* test: add more tests
This commit is contained in:
Kevin Wan
2021-10-19 22:37:56 +08:00
committed by GitHub
parent d41163f5c1
commit eab77e21dd
5 changed files with 112 additions and 7 deletions

View File

@@ -0,0 +1,12 @@
package trace
import (
"testing"
"github.com/stretchr/testify/assert"
gcodes "google.golang.org/grpc/codes"
)
func TestStatusCodeAttr(t *testing.T) {
assert.Equal(t, GRPCStatusCodeKey.Int(int(gcodes.DataLoss)), StatusCodeAttr(gcodes.DataLoss))
}