fix(reduceErrors): return error when given an empty list (#675)
See https://github.com/ooni/probe/issues/1985 for context. While there, ensure nextlite has 100% of coverage.
This commit is contained in:
parent
4d50dd6d54
commit
ce8ec5b391
5 changed files with 18 additions and 3 deletions
|
|
@ -439,7 +439,6 @@ func TestHTTPTLSDialerWithReadTimeout(t *testing.T) {
|
|||
}
|
||||
|
||||
func TestNewHTTPTransportStdlib(t *testing.T) {
|
||||
// What to test about this factory?
|
||||
txp := NewHTTPTransportStdlib(log.Log)
|
||||
ctx, cancel := context.WithCancel(context.Background())
|
||||
cancel() // immediately!
|
||||
|
|
@ -454,6 +453,9 @@ func TestNewHTTPTransportStdlib(t *testing.T) {
|
|||
if resp != nil {
|
||||
t.Fatal("unexpected resp")
|
||||
}
|
||||
if txp.Network() != "tcp" {
|
||||
t.Fatal("unexpected .Network return value")
|
||||
}
|
||||
txp.CloseIdleConnections()
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue