emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/buttercup 6590360 226/340: Fix a few typos and other small


From: ELPA Syncer
Subject: [nongnu] elpa/buttercup 6590360 226/340: Fix a few typos and other small errors
Date: Thu, 16 Dec 2021 14:59:39 -0500 (EST)

branch: elpa/buttercup
commit 65903604d1855c3bfad24c54682172309f9d67e5
Author: Ryan C. Thompson <rct@thompsonclan.org>
Commit: Ryan C. Thompson <rct@thompsonclan.org>

    Fix a few typos and other small errors
---
 buttercup.el            |  4 ++--
 tests/test-buttercup.el | 13 +++++--------
 2 files changed, 7 insertions(+), 10 deletions(-)

diff --git a/buttercup.el b/buttercup.el
index fdddc7e..a360a4b 100644
--- a/buttercup.el
+++ b/buttercup.el
@@ -1133,8 +1133,8 @@ responsibility to ensure ARG is a command."
                                  :return-value nil
                                  :thrown-signal err
                                  :current-buffer (current-buffer))))
-            ;; Regardless, we only caught this error order to record
-            ;; it, so we need to re-throw it.
+            ;; Regardless, we only caught this error in order to
+            ;; record it, so we need to re-throw it.
             (signal (car err) (cdr err)))))))
     ;; Add the interactive form from `fun', if any
     (when (interactive-form fun)
diff --git a/tests/test-buttercup.el b/tests/test-buttercup.el
index 8c27bf8..c2e8317 100644
--- a/tests/test-buttercup.el
+++ b/tests/test-buttercup.el
@@ -619,8 +619,6 @@
     ;; We use `before-all' here because some tests need to access the
     ;; same function as previous tests in order to work, so overriding
     ;; the function before each test would invalidate those tests.
-    ;; Unfortunately there's no way to do this lexically, so these
-    ;; function definitions are leaked after the tests run.
     (before-all
       (setq saved-test-function (and (fboundp 'test-function)
                                      (symbol-function 'test-function))
@@ -644,8 +642,8 @@
           (fset 'test-command saved-test-command)
         (fmakunbound 'test-command))
       (if saved-test-function-throws-on-negative
-          (fset 'test-test-function-throws-on-negative
-                test-function-throws-on-negative)
+          (fset 'test-function-throws-on-negative
+                saved-test-function-throws-on-negative)
         (fmakunbound 'test-function-throws-on-negative)))
 
     (describe "`spy-on' function"
@@ -936,10 +934,9 @@
         (expect (spy-context-thrown-signal
                  (spy-calls-first 'test-function-throws-on-negative))
                 :to-be nil)
-        (expect (car
-                 (spy-context-thrown-signal
-                  (spy-calls-most-recent 'test-function-throws-on-negative)))
-                :to-be 'error)))))
+        (expect (spy-context-thrown-signal
+                 (spy-calls-most-recent 'test-function-throws-on-negative))
+                :to-equal '(error "x is less than zero"))))))
 
 ;;;;;;;;;;;;;
 ;;; Reporters



reply via email to

[Prev in Thread] Current Thread [Next in Thread]