aboutsummaryrefslogtreecommitdiff
path: root/test/mastodon-http-tests.el
diff options
context:
space:
mode:
authorJohnson Denen <johnson.denen@gmail.com>2017-04-13 08:59:34 -0400
committerJohnson Denen <johnson.denen@gmail.com>2017-04-14 13:18:14 -0400
commitf42d5e2666022c891f8561c24489bc52e9f4f642 (patch)
tree573e5e5913a356d38436dea2b2abccf4345bf2d6 /test/mastodon-http-tests.el
parent523bf47c32d52d9bc99912d901ec5e6708f21fa5 (diff)
Use synchronous calls for simpler JSON parsing
Diffstat (limited to 'test/mastodon-http-tests.el')
-rw-r--r--test/mastodon-http-tests.el5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/mastodon-http-tests.el b/test/mastodon-http-tests.el
index afc8fe3..55f6bf3 100644
--- a/test/mastodon-http-tests.el
+++ b/test/mastodon-http-tests.el
@@ -6,5 +6,6 @@
"Should make a `url-retrieve' of the given URL."
(let ((callback-double (lambda () "double")))
(with-mock
- (mock (url-retrieve "https://foo.bar/baz" 'callback-double))
- (mastodon-http--get "https://foo.bar/baz" 'callback-double))))
+ (mock (url-retrieve-synchronously "https://foo.bar/baz"))
+ (mock (mastodon--access-token) => "test-token")
+ (mastodon-http--get "https://foo.bar/baz"))))