Conver to regular Go vendor + dep tool

This commit is contained in:
Andrey Smirnov
2017-03-22 17:38:32 +03:00
parent 070347295e
commit c6c1012330
3260 changed files with 1742550 additions and 72 deletions
+20
View File
@@ -0,0 +1,20 @@
package pb
import "testing"
func Test_RuneCount(t *testing.T) {
s := string([]byte{
27, 91, 51, 49, 109, // {Red}
72, 101, 108, 108, 111, // Hello
44, 32, // ,
112, 108, 97, 121, 103, 114, 111, 117, 110, 100, // Playground
27, 91, 48, 109, // {Reset}
})
if e, l := 17, escapeAwareRuneCountInString(s); l != e {
t.Errorf("Invalid length %d, expected %d", l, e)
}
s = "進捗 "
if e, l := 5, escapeAwareRuneCountInString(s); l != e {
t.Errorf("Invalid length %d, expected %d", l, e)
}
}