diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/test-org-drill-response-and-timer.el | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/test-org-drill-response-and-timer.el b/tests/test-org-drill-response-and-timer.el index 4da8e9a..e3c198a 100644 --- a/tests/test-org-drill-response-and-timer.el +++ b/tests/test-org-drill-response-and-timer.el @@ -104,5 +104,17 @@ exit-recursive-edit and kill-buffer are stubbed." (should (= (point-min) (point-max)))) (kill-buffer buf)))) +(ert-deftest test-response-get-buffer-create-with-active-input-method-propagates () + "If an input method is active, it's activated in the new buffer." + (let ((activated-with nil)) + (cl-letf (((symbol-function 'activate-input-method) + (lambda (im) (setq activated-with im))) + ((symbol-function 'set-input-method) #'ignore)) + (let ((current-input-method 'pretend-im)) + (let ((buf (org-drill-response-get-buffer-create))) + (unwind-protect + (should (eq 'pretend-im activated-with)) + (kill-buffer buf))))))) + (provide 'test-org-drill-response-and-timer) ;;; test-org-drill-response-and-timer.el ends here |
