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

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

[nongnu] elpa/buttercup 17f3cf5 062/340: Remove error in favor of failed


From: ELPA Syncer
Subject: [nongnu] elpa/buttercup 17f3cf5 062/340: Remove error in favor of failed.
Date: Thu, 16 Dec 2021 14:59:05 -0500 (EST)

branch: elpa/buttercup
commit 17f3cf570cb6a5923afd0a2c56f6d2504b141dea
Author: Jorgen Schaefer <contact@jorgenschaefer.de>
Commit: Jorgen Schaefer <contact@jorgenschaefer.de>

    Remove error in favor of failed.
    
    There is no big semantic difference outside of a lacking stack trace,
    and a lot more overlap than difference.
---
 buttercup-test.el | 2 +-
 buttercup.el      | 6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/buttercup-test.el b/buttercup-test.el
index eb24062..9d8bd4d 100644
--- a/buttercup-test.el
+++ b/buttercup-test.el
@@ -604,7 +604,7 @@
            res)))
 
 (let ((res (buttercup--funcall (lambda () (/ 1 0)))))
-  (when (not (equal res (list 'error
+  (when (not (equal res (list 'failed
                               '(error (arith-error))
                               (list '(t / 1 0)))))
     (error "Expected erroring buttercup--funcall not to return %S"
diff --git a/buttercup.el b/buttercup.el
index a5c65b8..e82950e 100644
--- a/buttercup.el
+++ b/buttercup.el
@@ -227,7 +227,7 @@ MATCHER is either a matcher defined with
   after-all
   ;; These are set if there are errors in after-all.
   ;; One of: passed failed pending
-  status
+  (status 'passed)
   failure-description
   failure-stack)
 
@@ -239,7 +239,7 @@ MATCHER is either a matcher defined with
   ;; The closure to run for this spec
   function
   ;; One of: passed failed pending
-  status
+  (status 'passed)
   failure-description
   failure-stack)
 
@@ -795,7 +795,7 @@ failed -- The second value is the description of the 
expectation
          (if (and (eq (elt args 0) 'error)
                   (eq (car (elt args 1)) 'buttercup-failed))
              (list 'failed (cdr (elt args 1)) nil)
-           (list 'error args (buttercup--backtrace)))))
+           (list 'failed args (buttercup--backtrace)))))
 
 (defun buttercup--backtrace ()
   (let* ((n 0)



reply via email to

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