branch: externals/ivy-hydra
commit d3c6cc1b00b6ffa1ffb1b604c03fd307a4ba5f85
Author: Basil L. Contovounesios <[email protected]>
Commit: Oleh Krehel <[email protected]>

    Adapt tests to when wgrep is not installed
    
    ivy-test.el (ivy-swiper-wgrep): Make test more reliable by skipping
    if conditions aren't met instead of trying to predict whether things
    will fail.  Skip test if wgrep is not installed and bump its Emacs
    version requirement to Emacs 25 or later, which has been the case
    since 2018:
    
    
https://github.com/mhayashi1120/Emacs-wgrep/commit/6f04cd7aa2ad67983082f778f0e34fb28970866a
    
    Fixes #2522
---
 ivy-test.el | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/ivy-test.el b/ivy-test.el
index e1b2174..1ab10bd 100644
--- a/ivy-test.el
+++ b/ivy-test.el
@@ -1365,11 +1365,9 @@ a buffer visiting a file."
     "Foo\nfoo|\nFOO\n")))
 
 (ert-deftest ivy-swiper-wgrep ()
-  :expected-result (if (and (= emacs-major-version 24)
-                            (<= emacs-minor-version 3))
-                       ;; `wgrep' requires at least 24.5
-                       :failed
-                     :passed)
+  ;; `wgrep' requires Emacs 25 or later.
+  (skip-unless (and (>= emacs-major-version 25)
+                    (require 'wgrep nil t)))
   (dolist (search-cmd '(swiper swiper-isearch))
     (should
      (string=

Reply via email to