* Re: emacs-30 7a8ca202c5e: Fix flakey proced refine tests (Bug#73441)
2024-11-20 14:46 ` emacs-30 7a8ca202c5e: Fix flakey proced refine tests (Bug#73441) Robert Pluim
@ 2024-11-21 19:18 ` Laurence Warne
0 siblings, 0 replies; 2+ messages in thread
From: Laurence Warne @ 2024-11-21 19:18 UTC (permalink / raw)
To: Robert Pluim; +Cc: emacs-devel
[-- Attachment #1.1: Type: text/plain, Size: 1520 bytes --]
Hi,
I've attached a small patch for this.
Thanks, Laurence
On Wed, Nov 20, 2024 at 2:46 PM Robert Pluim <rpluim@gmail.com> wrote:
> >>>>> On Sun, 27 Oct 2024 11:50:32 -0400 (EDT), Michael Albinus via
> Mailing list for Emacs changes <emacs-diffs@gnu.org> said:
>
> Michael> branch: emacs-30
> Michael> commit 7a8ca202c5eeb810e5f86510c3ea46d3ec519222
> Michael> Author: Laurence Warne <laurencewarne@gmail.com>
> Michael> Commit: Michael Albinus <michael.albinus@gmx.de>
>
> Michael> Fix flakey proced refine tests (Bug#73441)
>
> Michael> * test/lisp/proced-tests.el (proced-refine-test)
> Michael> (proced-refine-with-update-test): Use the much simpler
> CPU refinement
> Michael> for testing 'proced-refine'. The previous tests made the
> incorrect
> Michael> assumption that refining on the PID of process A only
> filtered the
> Michael> buffer to contain process A and its children, whereas in
> actuality
> Michael> the children of process A's children, their children, and
> so on will
> Michael> also be shown.
> Michael> (proced-update-preserves-pid-at-point-test): Mark as
> unstable.
>
> This causes proced-refine-test and proced-refine-with-update test
> failures on macOS, where %CPU is not implemented [1]. Probably we should
> stick a check for darwin around them in emacs-30.
>
> Robert
>
> Footnotes:
> [1] Probably because it appears to be non-trivial.
>
> --
>
[-- Attachment #1.2: Type: text/html, Size: 2212 bytes --]
[-- Attachment #2: 0001-Skip-proced-refine-tests-on-Darwin.patch --]
[-- Type: text/x-patch, Size: 1031 bytes --]
From 1b53602e9edc02aadb7a59ce79315077f1d71490 Mon Sep 17 00:00:00 2001
From: Laurence Warne <laurencewarne@gmail.com>
Date: Thu, 21 Nov 2024 17:26:25 +0000
Subject: [PATCH] Skip proced refine tests on Darwin
* test/lisp/proced-tests.el (proced-refine-test)
(proced-refine-with-update-test): Skip if the system is Darwin.
---
test/lisp/proced-tests.el | 3 +++
1 file changed, 3 insertions(+)
diff --git a/test/lisp/proced-tests.el b/test/lisp/proced-tests.el
index 3dc7e065afa..32dc5cff5f2 100644
--- a/test/lisp/proced-tests.el
+++ b/test/lisp/proced-tests.el
@@ -102,6 +102,8 @@ proced-color-test
(proced--assert-emacs-pid-in-buffer))))
(ert-deftest proced-refine-test ()
+ ;; %CPU is not implemented on macOS
+ (skip-when (eq system-type 'darwin))
(proced--within-buffer
'verbose
'user
@@ -115,6 +117,7 @@ proced-refine-test
(forward-line)))))
(ert-deftest proced-refine-with-update-test ()
+ (skip-when (eq system-type 'darwin))
(proced--within-buffer
'verbose
'user
--
2.39.5
^ permalink raw reply related [flat|nested] 2+ messages in thread