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

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

[nongnu] elpa/buttercup ec4d94f7d5 3/9: tests: Create enclosed expressio


From: ELPA Syncer
Subject: [nongnu] elpa/buttercup ec4d94f7d5 3/9: tests: Create enclosed expressions with buttercup--wrap-expr
Date: Wed, 10 Aug 2022 18:58:13 -0400 (EDT)

branch: elpa/buttercup
commit ec4d94f7d50a8a3ed5ac3ae7f57f0bfbe250a4e1
Author: Ola Nilsson <ola.nilsson@gmail.com>
Commit: Ola Nilsson <ola.nilsson@gmail.com>

    tests: Create enclosed expressions with buttercup--wrap-expr
    
    ... instead of creating wrapped functions manually.  At least in the
    cases where the wrapping and unwrapping is not the focus of the tests.
---
 tests/test-buttercup.el | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/tests/test-buttercup.el b/tests/test-buttercup.el
index b9456ffa4a..17a49e036b 100644
--- a/tests/test-buttercup.el
+++ b/tests/test-buttercup.el
@@ -182,17 +182,17 @@ text properties using `ansi-color-apply'."
   (describe "with a function as a matcher argument"
     (it "should not raise an error if the function returns true"
       (expect (buttercup-expect
-               (lambda () t)
+               (buttercup--wrap-expr t)
                #'eq
-               (lambda () t))
+               (buttercup--wrap-expr t))
               :not :to-throw
               'buttercup-failed))
 
     (it "should raise an error if the function returns false"
       (expect (buttercup-expect
-               (lambda () t)
+               (buttercup--wrap-expr t)
                #'eq
-               (lambda () nil))
+               (buttercup--wrap-expr nil))
               :to-throw
               'buttercup-failed)))
 
@@ -206,7 +206,7 @@ text properties using `ansi-color-apply'."
               'buttercup-failed))
 
     (it "should raise an error if the matcher returns false"
-      (expect (buttercup-expect (lambda () 1) :always-false)
+      (expect (buttercup-expect (buttercup--wrap-expr 1) :always-false)
               :to-throw
               'buttercup-failed))))
 



reply via email to

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