[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] scratch/nonspecial-handlers 3b4d893 1/2: Refine expectatio
From: |
Noam Postavsky |
Subject: |
[Emacs-diffs] scratch/nonspecial-handlers 3b4d893 1/2: Refine expectations for dired-compress-handler test |
Date: |
Sun, 28 Jan 2018 09:50:16 -0500 (EST) |
branch: scratch/nonspecial-handlers
commit 3b4d8930fc0afbcd22c22442598bfad819b9be4b
Author: Noam Postavsky <address@hidden>
Commit: Noam Postavsky <address@hidden>
Refine expectations for dired-compress-handler test
* test/lisp/files-tests.el
(files-file-name-non-special-dired-compress-handler): Skip if regular
file name contains ":" (e.g., on windows-nt).
---
test/lisp/files-tests.el | 16 +++++++---------
1 file changed, 7 insertions(+), 9 deletions(-)
diff --git a/test/lisp/files-tests.el b/test/lisp/files-tests.el
index 7fc5108..56bef24 100644
--- a/test/lisp/files-tests.el
+++ b/test/lisp/files-tests.el
@@ -348,16 +348,14 @@ be invoked with the right arguments."
(ert-deftest files-file-name-non-special-dired-compress-handler ()
;; `dired-compress-file' can get confused by filenames with ":" in
- ;; them, which causes this to fail on `windows-nt' systems. This
- ;; test does seem to pass on GNU/Linux systems, but it's not clear
- ;; why since the "/:" quoted file names also have ":" in them. Just
- ;; skip for now.
- (ert-skip "FIXME: dired-compress-file unreliable for names containing `:'." )
- (files-tests--with-temp-file tmpfile
- (let* ((nospecial (concat "/:" tmpfile))
- (compressed (dired-compress-file nospecial)))
+ ;; them, which causes this to fail on `windows-nt' systems.
+ (when (string-match-p ":" (expand-file-name temporary-file-directory))
+ (ert-skip "FIXME: `dired-compress-file' unreliable when filenames contain
`:'."))
+ (files-tests--with-temp-non-special (tmpfile nospecial)
+ (let ((compressed (dired-compress-file nospecial)))
(when compressed
- (should (equal nospecial (dired-compress-file compressed)))))))
+ ;; FIXME: Should it return a still-quoted name?
+ (should (file-equal-p nospecial (dired-compress-file compressed)))))))
(ert-deftest files-file-name-non-special-handlers ()
(files-tests--with-temp-file tmpfile