emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] trunk r116508: * automated/tramp-tests.el


From: Michael Albinus
Subject: [Emacs-diffs] trunk r116508: * automated/tramp-tests.el
Date: Fri, 21 Feb 2014 10:43:53 +0000
User-agent: Bazaar (2.6b2)

------------------------------------------------------------
revno: 116508
revision-id: address@hidden
parent: address@hidden
committer: Michael Albinus <address@hidden>
branch nick: trunk
timestamp: Fri 2014-02-21 11:43:49 +0100
message:
  * automated/tramp-tests.el
  (tramp-test19-directory-files-and-attributes): Do not include
  directories in comparison; they might have changed their
  timestamps already.
modified:
  test/ChangeLog                 changelog-20091113204419-o5vbwnq5f7feedwu-8588
  test/automated/tramp-tests.el  tramptests.el-20131105142319-d9zp3oprkpxj5v1e-1
=== modified file 'test/ChangeLog'
--- a/test/ChangeLog    2014-02-20 14:08:00 +0000
+++ b/test/ChangeLog    2014-02-21 10:43:49 +0000
@@ -1,3 +1,10 @@
+2014-02-21  Michael Albinus  <address@hidden>
+
+       * automated/tramp-tests.el
+       (tramp-test19-directory-files-and-attributes): Do not include
+       directories in comparison; they might have changed their
+       timestamps already.
+
 2014-02-20  Michael Albinus  <address@hidden>
 
        * automated/tramp-tests.el (tramp--instrument-test-case): New macro.

=== modified file 'test/automated/tramp-tests.el'
--- a/test/automated/tramp-tests.el     2014-02-20 18:26:40 +0000
+++ b/test/automated/tramp-tests.el     2014-02-21 10:43:49 +0000
@@ -906,13 +906,19 @@
          (setq attr (directory-files-and-attributes tmp-name))
          (should (consp attr))
          (dolist (elt attr)
-           (should
-            (equal (file-attributes (expand-file-name (car elt) tmp-name))
-                   (cdr elt))))
+           ;; We cannot include "." and "..".  They might have
+           ;; changed their timestamp already.
+           (when (string-match "foo$\\|bar$\\|baz$" (car elt))
+             (should
+              (equal (file-attributes (expand-file-name (car elt) tmp-name))
+                     (cdr elt)))))
          (setq attr (directory-files-and-attributes tmp-name 'full))
          (dolist (elt attr)
-           (should
-            (equal (file-attributes (car elt)) (cdr elt))))
+           ;; We cannot include "." and "..".  They might have
+           ;; changed their timestamp already.
+           (when (string-match "foo$\\|bar$\\|baz$" (car elt))
+             (should
+              (equal (file-attributes (car elt)) (cdr elt)))))
          (setq attr (directory-files-and-attributes tmp-name nil "^b"))
          (should (equal (mapcar 'car attr) '("bar" "boz"))))
       (ignore-errors (delete-directory tmp-name 'recursive))))))


reply via email to

[Prev in Thread] Current Thread [Next in Thread]