add new commit
This commit is contained in:
parent
7544964508
commit
ea59675755
12 changed files with 123 additions and 38 deletions
|
@ -96,6 +96,7 @@ func TestAuthenticate(t *testing.T) {
|
|||
return
|
||||
}
|
||||
fmt.Fprintln(w, `{"access_token": "zoo"}`)
|
||||
return
|
||||
}))
|
||||
defer ts.Close()
|
||||
|
||||
|
@ -123,6 +124,7 @@ func TestAuthenticate(t *testing.T) {
|
|||
func TestAuthenticateWithCancel(t *testing.T) {
|
||||
ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||
time.Sleep(3 * time.Second)
|
||||
return
|
||||
}))
|
||||
defer ts.Close()
|
||||
|
||||
|
@ -149,6 +151,7 @@ func TestPostStatus(t *testing.T) {
|
|||
return
|
||||
}
|
||||
fmt.Fprintln(w, `{"access_token": "zoo"}`)
|
||||
return
|
||||
}))
|
||||
defer ts.Close()
|
||||
|
||||
|
@ -181,6 +184,7 @@ func TestPostStatus(t *testing.T) {
|
|||
func TestPostStatusWithCancel(t *testing.T) {
|
||||
ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||
time.Sleep(3 * time.Second)
|
||||
return
|
||||
}))
|
||||
defer ts.Close()
|
||||
|
||||
|
@ -315,6 +319,7 @@ func TestPostStatusParams(t *testing.T) {
|
|||
func TestGetTimelineHome(t *testing.T) {
|
||||
ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||
fmt.Fprintln(w, `[{"content": "foo"}, {"content": "bar"}]`)
|
||||
return
|
||||
}))
|
||||
defer ts.Close()
|
||||
|
||||
|
@ -354,6 +359,7 @@ func TestGetTimelineHome(t *testing.T) {
|
|||
func TestGetTimelineHomeWithCancel(t *testing.T) {
|
||||
ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||
time.Sleep(3 * time.Second)
|
||||
return
|
||||
}))
|
||||
defer ts.Close()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue