mirror of
https://github.com/amix/vimrc
synced 2025-07-09 10:45:00 +08:00
Removed vim-go
This commit is contained in:
@ -1,5 +0,0 @@
|
||||
package main
|
||||
|
||||
func main() {
|
||||
notafunc()
|
||||
}
|
@ -1,9 +0,0 @@
|
||||
package complete
|
||||
|
||||
type T struct {
|
||||
V string
|
||||
}
|
||||
|
||||
func Example(s string) {
|
||||
Example("")
|
||||
}
|
@ -1,5 +0,0 @@
|
||||
package config
|
||||
|
||||
func Example() {
|
||||
foo()
|
||||
}
|
@ -1,8 +0,0 @@
|
||||
// +build constrained
|
||||
|
||||
package config
|
||||
|
||||
// foo is constrained and this comment exists to make the line numbers different than foo.go
|
||||
func foo() {
|
||||
println("foo")
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
// +build !constrained
|
||||
|
||||
package config
|
||||
|
||||
func foo() {
|
||||
println("foo")
|
||||
}
|
@ -1,3 +0,0 @@
|
||||
module config
|
||||
|
||||
go 1.13
|
@ -1,7 +0,0 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
fmt.Println("vim-go"
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
fmt.Println("vim-go")
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
fmt.Println("vim-go")
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
fmt.Println("vim-go")
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
fmt.Println("vim-go")
|
||||
}
|
@ -1,13 +0,0 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
)
|
||||
|
||||
func Foo(log *logging.TestLogger) {
|
||||
log.Debug("vim-go")
|
||||
}
|
||||
|
||||
func main() {
|
||||
fmt.Println("vim-go")
|
||||
}
|
@ -1,15 +0,0 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
logging "gh.com/gi/foo-logging"
|
||||
)
|
||||
|
||||
func Foo(log *logging.TestLogger) {
|
||||
log.Debug("vim-go")
|
||||
}
|
||||
|
||||
func main() {
|
||||
fmt.Println("vim-go")
|
||||
}
|
@ -1,12 +0,0 @@
|
||||
package logging
|
||||
|
||||
import "fmt"
|
||||
|
||||
type TestLogger struct {
|
||||
Value string
|
||||
}
|
||||
|
||||
func (l *TestLogger) Debug(msg string) {
|
||||
fmt.Println(msg)
|
||||
fmt.Println(l.Value)
|
||||
}
|
@ -1 +0,0 @@
|
||||
../imports/
|
@ -1,6 +0,0 @@
|
||||
package main
|
||||
|
||||
func main() {
|
||||
notafunc()
|
||||
println("vim-go")
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
package foo
|
||||
|
||||
import "fmt"
|
||||
|
||||
func MissingFooDoc() {
|
||||
fmt.Println("missing doc")
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
package lint
|
||||
|
||||
import "fmt"
|
||||
|
||||
func MissingDoc() {
|
||||
fmt.Println("missing doc")
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
package lint
|
||||
|
||||
import "fmt"
|
||||
|
||||
func AlsoMissingDoc() {
|
||||
fmt.Println("missing doc")
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
fmt.Println("vim-go"
|
||||
}
|
@ -1,8 +0,0 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
str := "hello world!"
|
||||
fmt.Printf("%d\n", str)
|
||||
}
|
@ -1,3 +0,0 @@
|
||||
module package
|
||||
|
||||
go 1.12
|
@ -1,7 +0,0 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
fmt.Println("vim-go")
|
||||
}
|
@ -1,5 +0,0 @@
|
||||
package main
|
||||
|
||||
func main() {
|
||||
println("hello, world")
|
||||
}
|
@ -1 +0,0 @@
|
||||
/pkg
|
@ -1,7 +0,0 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
fmt.Println("vim-go"
|
||||
}
|
@ -1,10 +0,0 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
)
|
||||
|
||||
func ExampleHelloWorld() {
|
||||
fmt.Println("Hello, World")
|
||||
// Output: What's shakin
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
package mock
|
||||
|
||||
import "testing"
|
||||
|
||||
func Fail(t *testing.T) {
|
||||
t.Fatal("another package badness")
|
||||
}
|
@ -1,59 +0,0 @@
|
||||
package play
|
||||
|
||||
import (
|
||||
"sync"
|
||||
"testing"
|
||||
|
||||
"play/mock"
|
||||
)
|
||||
|
||||
func TestTopSubHelper(t *testing.T) {
|
||||
t.Run("sub", func(t *testing.T) {
|
||||
t.Log("log message")
|
||||
t.Error("sub badness")
|
||||
})
|
||||
t.Error("badness")
|
||||
helper(t)
|
||||
}
|
||||
|
||||
func TestMultiline(t *testing.T) {
|
||||
t.Error("this is an error\nand a second line, too")
|
||||
t.Error("\nthis is another error")
|
||||
}
|
||||
|
||||
func TestSub(t *testing.T) {
|
||||
t.Run("indented", func(t *testing.T) {
|
||||
t.Error("this is a sub-test error\nand a second line, too")
|
||||
})
|
||||
}
|
||||
|
||||
func TestOK(t *testing.T) {
|
||||
t.Run("log", func(t *testing.T) {
|
||||
t.Log("goodness")
|
||||
})
|
||||
}
|
||||
|
||||
// TestMocked tests behavior similar to what users may experience when using
|
||||
// github.com/golang/mock/gomock.
|
||||
func TestMocked(t *testing.T) {
|
||||
mock.Fail(t)
|
||||
}
|
||||
|
||||
func TestPanic(t *testing.T) {
|
||||
panic("worst ever")
|
||||
}
|
||||
|
||||
func TestConcurrentPanic(t *testing.T) {
|
||||
var wg sync.WaitGroup
|
||||
wg.Add(1)
|
||||
go func() {
|
||||
panic("concurrent fail")
|
||||
wg.Done()
|
||||
}()
|
||||
wg.Wait()
|
||||
}
|
||||
|
||||
func helper(t *testing.T) {
|
||||
t.Helper()
|
||||
t.Fatal("helper badness")
|
||||
}
|
@ -1,11 +0,0 @@
|
||||
package main
|
||||
|
||||
import "testing"
|
||||
|
||||
func TestHelloWorld(t *testing.T) {
|
||||
t.Error("so long")
|
||||
|
||||
t.Run("sub", func(t *testing.T) {
|
||||
t.Error("thanks for all the fish")
|
||||
})
|
||||
}
|
@ -1,11 +0,0 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"io/ioutil"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestSomething(t *testing.T) {
|
||||
r := struct{}{}
|
||||
ioutil.ReadAll(r)
|
||||
}
|
@ -1,47 +0,0 @@
|
||||
// Run a few parallel tests, all in parallel, using multiple techniques for
|
||||
// causing the test to take a while so that the stacktraces resulting from a
|
||||
// test timeout will contain several goroutines to avoid giving a false sense
|
||||
// of confidence or creating error formats that don't account for the more
|
||||
// complex scenarios that can occur with timeouts.
|
||||
|
||||
package main
|
||||
|
||||
import (
|
||||
"testing"
|
||||
"time"
|
||||
)
|
||||
|
||||
func TestSleep(t *testing.T) {
|
||||
t.Parallel()
|
||||
time.Sleep(15 * time.Second)
|
||||
t.Log("expected panic if run with timeout < 15s")
|
||||
}
|
||||
|
||||
func TestRunning(t *testing.T) {
|
||||
t.Parallel()
|
||||
c := time.After(15 * time.Second)
|
||||
Loop:
|
||||
for {
|
||||
select {
|
||||
case <-c:
|
||||
break Loop
|
||||
default:
|
||||
}
|
||||
}
|
||||
|
||||
t.Log("expected panic if run with timeout < 15s")
|
||||
}
|
||||
|
||||
func TestRunningAlso(t *testing.T) {
|
||||
t.Parallel()
|
||||
c := time.After(15 * time.Second)
|
||||
Loop:
|
||||
for {
|
||||
select {
|
||||
case <-c:
|
||||
break Loop
|
||||
default:
|
||||
}
|
||||
}
|
||||
t.Log("expected panic if run with timeout < 15s")
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
fmt.Errorf("%v")
|
||||
}
|
Reference in New Issue
Block a user