mirror of
https://github.com/aler9/rtsp-simple-server
synced 2025-10-23 15:43:17 +08:00
fix tests that involve HTTP clients
This commit is contained in:
@@ -60,6 +60,10 @@ func httpRequest(method string, ur string, in interface{}, out interface{}) erro
|
||||
}
|
||||
|
||||
func TestAPIConfigGet(t *testing.T) {
|
||||
// since the HTTP server is created and deleted multiple times,
|
||||
// we can't reuse TCP connections.
|
||||
http.DefaultTransport.(*http.Transport).DisableKeepAlives = true
|
||||
|
||||
p, ok := newInstance("api: yes\n")
|
||||
require.Equal(t, true, ok)
|
||||
defer p.close()
|
||||
|
Reference in New Issue
Block a user