fix example JSON/YAML file path

This commit is contained in:
buyuxiang
2022-03-03 19:43:36 +08:00
parent 026131b604
commit 8459e3fab4
2 changed files with 6 additions and 3 deletions

View File

@@ -7,6 +7,8 @@ import (
"github.com/httprunner/hrp/internal/builtin"
)
const rendezvousTestJSONPath = "rendezvous_test.json"
var rendezvousTestcase = &hrp.TestCase{
Config: hrp.NewConfig("run request with functions").
SetBaseURL("https://postman-echo.com").
@@ -59,7 +61,7 @@ func TestRendezvousDump2JSON(t *testing.T) {
if err != nil {
t.Fatalf("ToTCase error: %v", err)
}
err = builtin.Dump2JSON(tCase, "rendezvous_test.json")
err = builtin.Dump2JSON(tCase, rendezvousTestJSONPath)
if err != nil {
t.Fatalf("dump to json error: %v", err)
}