| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- package main
- //
- //import (
- // "github.com/gogf/gf/net/ghttp"
- // "testing"
- //)
- //
- const (
- TestURL string = "http://127.0.0.1:80"
- )
- //
- //func TestLogTest(t *testing.T) {
- // if r, e := ghttp.Get(TestURL + "/tmp/test?name=john&age=18"); e != nil {
- // t.Error(e)
- // } else {
- // t.Log(string(r.ReadAll()))
- // r.Close()
- // }
- //}
- //
- //func TestLogPost(t *testing.T) {
- // if r, e := ghttp.Post(TestURL+"/tmp/access", "name=john&age=18"); e != nil {
- // t.Error(e)
- // } else {
- // t.Log(string(r.ReadAll()))
- // r.Close()
- // }
- //}
- //
- //func TestLogGet(t *testing.T) {
- // if r, e := ghttp.Get(TestURL + "/tmp/access?name=john&age=18"); e != nil {
- // t.Error(e)
- // } else {
- // t.Log(string(r.ReadAll()))
- // r.Close()
- // }
- //}
- //
- //func TestLogCache(t *testing.T) {
- // if r, e := ghttp.Get(TestURL + "/tmp/cache"); e != nil {
- // t.Error(e)
- // } else {
- // t.Log(string(r.ReadAll()))
- // r.Close()
- // }
- //}
- //
- //func TestLogMysql(t *testing.T) {
- // if r, e := ghttp.Get(TestURL + "/tmp/mysql"); e != nil {
- // t.Error(e)
- // } else {
- // t.Log(string(r.ReadAll()))
- // r.Close()
- // }
- //}
|