change: skip go plugin test for windows

This commit is contained in:
debugtalk
2021-12-28 22:26:27 +08:00
parent b573210644
commit 83e9bbf463
4 changed files with 48 additions and 32 deletions

View File

@@ -1,23 +1,12 @@
package hrp
import (
"fmt"
"os"
"os/exec"
"testing"
"github.com/stretchr/testify/assert"
)
func TestMain(m *testing.M) {
fmt.Println("[TestMain] build go plugin")
cmd := exec.Command("go", "build", "-buildmode=plugin", "-o=examples/debugtalk.so", "examples/plugin/debugtalk.go")
if err := cmd.Run(); err != nil {
panic(err)
}
os.Exit(m.Run())
}
func TestLocatePlugin(t *testing.T) {
cwd, _ := os.Getwd()
_, err := locatePlugin(cwd)