Skip to content

Commit

Permalink
fix(tests): base url
Browse files Browse the repository at this point in the history
  • Loading branch information
h2non committed Feb 17, 2020
1 parent df41097 commit 34f7cae
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .travis.yml
@@ -1,5 +1,7 @@
language: go

go_import_path: gopkg.in/h2non/gentleman.v2

go:
- "1.13"
- "1.12"
Expand Down
2 changes: 1 addition & 1 deletion client_test.go
Expand Up @@ -157,7 +157,7 @@ func TestClientBaseURL(t *testing.T) {
cli := New()
cli.BaseURL(url)
cli.Middleware.Run("request", cli.Context)
st.Expect(t, cli.Context.Request.URL.String(), "http://foo.com")
st.Expect(t, cli.Context.Request.URL.String(), "http://foo.com/bar/baz")
}

func TestClientPath(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion request_test.go
Expand Up @@ -311,7 +311,7 @@ func TestRequestBaseURL(t *testing.T) {
req := NewRequest()
req.BaseURL(url)
req.Middleware.Run("request", req.Context)
st.Expect(t, req.Context.Request.URL.String(), "http://foo.com")
st.Expect(t, req.Context.Request.URL.String(), "http://foo.com/bar/baz")
}

func TestRequestPath(t *testing.T) {
Expand Down

0 comments on commit 34f7cae

Please sign in to comment.