Commit 3ff7d732 authored by Michael Albinus's avatar Michael Albinus

Adapt tramp-test32-shell-command

* test/lisp/net/tramp-tests.el (tramp-test32-shell-command):
Check "tput" before running `shell-command-width' test.
parent f5e3c2cc
Pipeline #1346 failed with stage
in 49 minutes and 48 seconds
......@@ -4193,16 +4193,11 @@ This tests also `make-symbolic-link', `file-truename' and `add-name-to-file'."
(ignore-errors (delete-file tmp-name)))
;; Test `shell-command-width' of `async-shell-command'.
;; `executable-find' has changed the number of parameters in
;; Emacs 27.1, so we use `apply' for older Emacsen.
(when (and (executable-find "tput")
(apply #'executable-find '("tput" 'remote)))
(when (and (zerop (call-process "tput" nil nil nil "cols"))
(zerop (process-file "tput" nil nil nil "cols")))
(let (shell-command-width)
;; `frame-width' does not return a proper value.
;; `process-lines' uses `call-process', it doesn't care
;; about `shell-command-width'.
(format "%s\n" (car (process-lines "tput" "cols")))
"tput cols")))
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment