aboutsummaryrefslogtreecommitdiff
path: root/test/mastodon-profile-tests.el
diff options
context:
space:
mode:
authormarty hiatt <martianhiatus [a t] riseup [d o t] net>2022-11-24 14:27:00 +0100
committermarty hiatt <martianhiatus [a t] riseup [d o t] net>2022-11-24 14:27:00 +0100
commit01a0a7cf528c140c206fc2ee681836b51c5056a9 (patch)
treea5b2eaf2a078ced0898658f8406d2ce356101f72 /test/mastodon-profile-tests.el
parent69c817d1a901f0aaa871f2679659f64fc438c40b (diff)
parent54bf253a26c899a21dec819033b51831684a6eb5 (diff)
Merge branch 'params-always-in-http-el' into develop
Diffstat (limited to 'test/mastodon-profile-tests.el')
-rw-r--r--test/mastodon-profile-tests.el11
1 files changed, 8 insertions, 3 deletions
diff --git a/test/mastodon-profile-tests.el b/test/mastodon-profile-tests.el
index 704f2ce..7478aaf 100644
--- a/test/mastodon-profile-tests.el
+++ b/test/mastodon-profile-tests.el
@@ -172,7 +172,8 @@ The search will happen as if called without the \"@\"."
(with-mock
(mock (mastodon-http--get-json
- "https://instance.url/api/v1/accounts/search?q=gargron"))
+ "https://instance.url/api/v1/accounts/search"
+ '(("q" . "gargron"))))
(let ((mastodon-instance-url "https://instance.url"))
;; We don't check anything from the return value. We only care
@@ -182,7 +183,9 @@ The search will happen as if called without the \"@\"."
(ert-deftest mastodon-profile--search-account-by-handle--filters-out-false-results ()
"Should ignore results that don't match the searched handle."
(with-mock
- (mock (mastodon-http--get-json *)
+ (mock (mastodon-http--get-json
+ "https://instance.url/api/v1/accounts/search"
+ '(("q" . "Gargron")))
=>
(vector ccc-profile-json gargron-profile-json))
@@ -197,7 +200,9 @@ The search will happen as if called without the \"@\"."
TODO: We need to decide if this is actually desired or not."
(with-mock
- (mock (mastodon-http--get-json *) => (vector gargron-profile-json))
+ (mock (mastodon-http--get-json *
+ '(("q" . "gargron")))
+ => (vector gargron-profile-json))
(let ((mastodon-instance-url "https://instance.url"))
(should