From c68d79e36cb94a8854e0ab8e96fd6a91cf82d5b6 Mon Sep 17 00:00:00 2001 From: Peter Oliver Date: Fri, 12 Jul 2024 11:05:50 +0100 Subject: [PATCH] Fix intermittently failing test wdired-test-unfinished-edit-01. --- ...unfinished-edit-01-when-temp-dirname.patch | 29 +++++++++++++++++++ emacs.spec | 3 ++ 2 files changed, 32 insertions(+) create mode 100644 0001-Fix-wdired-test-unfinished-edit-01-when-temp-dirname.patch diff --git a/0001-Fix-wdired-test-unfinished-edit-01-when-temp-dirname.patch b/0001-Fix-wdired-test-unfinished-edit-01-when-temp-dirname.patch new file mode 100644 index 0000000..370d314 --- /dev/null +++ b/0001-Fix-wdired-test-unfinished-edit-01-when-temp-dirname.patch @@ -0,0 +1,29 @@ +From 90734f5a3ba9998886e0b03382878a2fb514d015 Mon Sep 17 00:00:00 2001 +From: Peter Oliver +Date: Fri, 12 Jul 2024 10:52:23 +0100 +Subject: [PATCH] Fix wdired-test-unfinished-edit-01 when temp dirname contains + "foo" + +* test/lisp/wdired-tests.el (wdired-test-unfinished-edit-01): Don't +modify the random directory name if, by chance, it happens to contain +the substring "foo". +--- + test/lisp/wdired-tests.el | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/test/lisp/wdired-tests.el b/test/lisp/wdired-tests.el +index f7bff743058..f6d2194e998 100644 +--- a/test/lisp/wdired-tests.el ++++ b/test/lisp/wdired-tests.el +@@ -114,7 +114,7 @@ wdired-test-unfinished-edit-01 + (setq test-dir (file-truename test-dir)) + (let* ((test-file (concat (file-name-as-directory test-dir) "foo.c")) + (replace "bar") +- (new-file (string-replace "foo" replace test-file))) ++ (new-file (string-replace "/foo" (concat "/" replace) test-file))) + (write-region "" nil test-file nil 'silent) + (let ((buf (find-file-noselect test-dir))) + (unwind-protect +-- +2.45.2 + diff --git a/emacs.spec b/emacs.spec index 839949b..01ebb52 100644 --- a/emacs.spec +++ b/emacs.spec @@ -43,6 +43,9 @@ Patch: emacs-pgtk-on-x-error-message.patch Patch: 0001-Fix-failing-help-fns-test.patch Patch: 0001-Fix-flymake-tests-with-GCC-14.patch +# Fix intermittently failing test (https://debbugs.gnu.org/cgi/bugreport.cgi?bug=72073) +Patch: 0001-Fix-wdired-test-unfinished-edit-01-when-temp-dirname.patch + ExcludeArch: %{ix86} BuildRequires: alsa-lib-devel