From 1fcdf9f501428b76a70824a6eb286708fb52f553 Mon Sep 17 00:00:00 2001 From: 178inaba <178inaba@users.noreply.github.com> Date: Thu, 14 Feb 2019 23:21:45 +0900 Subject: [PATCH] Fix TestPaginationSetValues --- mastodon_test.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/mastodon_test.go b/mastodon_test.go index e76cf3c..62ec165 100644 --- a/mastodon_test.go +++ b/mastodon_test.go @@ -328,7 +328,8 @@ func TestGetPaginationID(t *testing.T) { func TestPaginationSetValues(t *testing.T) { p := &Pagination{ MaxID: "123", - SinceID: "789", + SinceID: "456", + MinID: "789", Limit: 10, } before := url.Values{"key": {"value"}} @@ -339,7 +340,10 @@ func TestPaginationSetValues(t *testing.T) { if after.Get("max_id") != "123" { t.Fatalf("want %q but %q", "123", after.Get("max_id")) } - if after.Get("since_id") != "789" { + if after.Get("since_id") != "456" { + t.Fatalf("result should be empty string: %q", after.Get("since_id")) + } + if after.Get("min_id") != "789" { t.Fatalf("result should be empty string: %q", after.Get("since_id")) } if after.Get("limit") != "10" {