Skip to content

Commit f8feb8b

Browse files
committed
utils test
utils test class issue: #1
1 parent 1209e6d commit f8feb8b

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

utils_test.go

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
package godzilla
2+
3+
import "fmt"
4+
5+
func ExampleGetString() {
6+
b := []byte("ABC")
7+
str := GetString(b)
8+
fmt.Println(str)
9+
fmt.Println(len(b) == len(str))
10+
11+
b = nil
12+
str = GetString(b)
13+
fmt.Println(str)
14+
fmt.Println(len(b) == len(str))
15+
fmt.Println(len(str))
16+
}

0 commit comments

Comments
 (0)