mirror of
https://github.com/sourcegraph/sourcegraph.git
synced 2026-02-06 18:11:48 +00:00
[DO NOT MERGE]: Demo that nogo isn't running for tests
This commit is contained in:
parent
9145768648
commit
ded9e56609
@ -3,6 +3,7 @@ package metrics
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"io"
|
||||
"net"
|
||||
"net/http"
|
||||
"net/http/httptest"
|
||||
@ -17,6 +18,17 @@ import (
|
||||
"github.com/prometheus/client_golang/prometheus/testutil"
|
||||
)
|
||||
|
||||
func TestNoGo(t *testing.T) {
|
||||
t.Skip()
|
||||
resp, err := http.Get("https://example.com/") // Need to call Close()
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
body, err := io.ReadAll(resp.Body)
|
||||
_ = body
|
||||
_ = err
|
||||
}
|
||||
|
||||
func testingHTTPClient(handler http.Handler) (*http.Client, func()) {
|
||||
s := httptest.NewServer(handler)
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user