package test import ( "net/http" "testing" ) func TestVersion(t *testing.T) { Init() defer Destroy() versionResponse := &struct{ Version string `json:"version"` }{} NewToolKit(t).SetJsonResponse(versionResponse). Request("/erpims/api/version", http.MethodGet). AssertStatusCode(http.StatusOK). AssertEqual(versionResponse.Version, "v1.0.0") }