mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-09 09:26:54 +00:00
18 lines
377 B
Go
18 lines
377 B
Go
// +build !appengine
|
|
|
|
package internal
|
|
|
|
import (
|
|
"go/build"
|
|
"path/filepath"
|
|
"testing"
|
|
)
|
|
|
|
func TestFindMainPath(t *testing.T) {
|
|
// Tests won't have package main, instead they have testing.tRunner
|
|
want := filepath.Join(build.Default.GOROOT, "src", "testing", "testing.go")
|
|
got := findMainPath()
|
|
if want != got {
|
|
t.Errorf("findMainPath: want %s, got %s", want, got)
|
|
}
|
|
}
|