]> git.lizzy.rs Git - micro.git/blobdiff - tools/testgen.go
Adjust default keybinding text (#2293)
[micro.git] / tools / testgen.go
index 6d53fa57d96861a64b6335a9ed63b8d3d2f3a953..f110202fa96e12907c755268cc763b0dd51c2a19 100644 (file)
@@ -1,3 +1,5 @@
+//+build ignore
+
 package main
 
 import (
@@ -233,8 +235,6 @@ func main() {
        re := regexp.MustCompile(`[^\w]`)
        usedNames := map[string]bool{}
 
-       var b strings.Builder
-
        for _, test := range tests {
                name := strings.Title(strings.ToLower(test.description))
                name = re.ReplaceAllLiteralString(name, "")
@@ -253,15 +253,5 @@ func main() {
                usedNames[name] = true
 
                fmt.Println(testToGoTest(test, name))
-
-               b.WriteString("Test")
-               b.WriteString(name)
-               b.WriteString("(nil)\n")
        }
-
-       fmt.Println("func BenchmarkBuffer(b *testing.B) {")
-       fmt.Println("for i := 0; i < b.N; i++ {")
-       fmt.Print(b.String())
-       fmt.Println("}")
-       fmt.Println("}")
 }