package recon import "time" // SetPortDialHook installs a test hook for TCP dials; pass nil to restore live dials. func SetPortDialHook(fn func(host string, port int, timeout time.Duration) bool) { dialPortFn = fn } // SetFetchPageHook installs a test hook for HTTP fetches; pass nil to restore live GETs. func SetFetchPageHook(fn func(rawURL string) (status int, body string, err error)) { fetchPageFn = fn }