From 4354b7dd3a6205018d3dc99cba547d5862da7889 Mon Sep 17 00:00:00 2001 From: marty hiatt Date: Sat, 12 Nov 2022 16:28:48 +0100 Subject: hack fix -toot--kill test: set mastodon-toot-previous-window-config --- test/mastodon-toot-tests.el | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/test/mastodon-toot-tests.el b/test/mastodon-toot-tests.el index 5b95cdc..39e0984 100644 --- a/test/mastodon-toot-tests.el +++ b/test/mastodon-toot-tests.el @@ -92,10 +92,13 @@ mention string." ;; TODO: test y-or-no-p with mastodon-toot--cancel (ert-deftest mastodon-toot--kill () "Should kill the buffer when cancelling the toot." - (with-mock - (mock (kill-buffer-and-window)) - (mastodon-toot--kill) - (mock-verify))) + (let ((mastodon-toot-previous-window-config + (list (current-window-configuration) + (point-marker)))) + (with-mock + (mock (kill-buffer-and-window)) + (mastodon-toot--kill) + (mock-verify)))) (ert-deftest mastodon-toot--own-toot-p-fail () "Should not return t if not own toot." -- cgit v1.2.3