cleanup: merge httpheader and httpfailure into model (#758)
These two small packages could easily be merged into the model package, since they're clearly model-like packages. Part of https://github.com/ooni/probe/issues/2115
This commit is contained in:
parent
928de50145
commit
2d721baa91
20 changed files with 74 additions and 90 deletions
|
|
@ -9,7 +9,7 @@ import (
|
|||
"testing"
|
||||
|
||||
"github.com/apex/log"
|
||||
"github.com/ooni/probe-cli/v3/internal/engine/httpheader"
|
||||
"github.com/ooni/probe-cli/v3/internal/model"
|
||||
)
|
||||
|
||||
func TestUbuntuParseError(t *testing.T) {
|
||||
|
|
@ -22,7 +22,7 @@ func TestUbuntuParseError(t *testing.T) {
|
|||
},
|
||||
}},
|
||||
log.Log,
|
||||
httpheader.UserAgent(),
|
||||
model.HTTPHeaderUserAgent,
|
||||
)
|
||||
if err == nil || !strings.HasPrefix(err.Error(), "XML syntax error") {
|
||||
t.Fatalf("not the error we expected: %+v", err)
|
||||
|
|
@ -37,7 +37,7 @@ func TestIPLookupWorksUsingUbuntu(t *testing.T) {
|
|||
context.Background(),
|
||||
http.DefaultClient,
|
||||
log.Log,
|
||||
httpheader.UserAgent(),
|
||||
model.HTTPHeaderUserAgent,
|
||||
)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
|
|
|
|||
Loading…
Reference in a new issue