branch: externals/urgrep commit d0012b9fcb924de2aa930d990256ec6455f9f2d0 Author: Jim Porter <jporterb...@gmail.com> Commit: Jim Porter <jporterb...@gmail.com>
Tweak tests so they only work around Emacs bug#58265 on older versions --- urgrep-tests.el | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/urgrep-tests.el b/urgrep-tests.el index 71d332e067..9271515cdb 100644 --- a/urgrep-tests.el +++ b/urgrep-tests.el @@ -3,8 +3,11 @@ ;; Copyright (C) 2021-2023 Jim Porter ;; Author: Jim Porter +;; URL: https://github.com/jimporter/urgrep ;; Keywords: tests +;; This file is NOT part of GNU Emacs. + ;; This program is free software; you can redistribute it and/or modify it ;; under the terms of the GNU General Public License as published by the Free ;; Software Foundation, either version 3 of the License, or (at your option) @@ -24,12 +27,14 @@ ;;; Code: -;; FIXME: Work around Emacs bug#58265. +(require 'ert) +(require 'tramp) + (let ((orig-home (getenv "HOME"))) - (require 'ert) - (require 'tramp) (require 'ert-x) - (setenv "HOME" orig-home)) + ;; Work around Emacs bug#58265. + (when (< emacs-major-version 29) + (setenv "HOME" orig-home))) (unless (fboundp 'always) (defun always (&rest _) t))