|
From: | Ken Brown |
Subject: | Re: [Emacs-diffs] master 716b468: Extend `file-notify-test02-rm-watch' |
Date: | Fri, 7 Apr 2017 10:56:31 -0400 |
User-agent: | Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 |
On 4/5/2017 10:59 PM, Ken Brown wrote:
On 4/5/2017 5:02 PM, Andreas Politz wrote:Ken Brown <address@hidden> writes:This may be another of those timing issues that we've dealt with before [...].I think it is as well. If cygwin's file-notify back-end runs on a polling timer, we need to make sure that it has acknowledged the file's existence before we delete it. Maybe you could try out the following patch. diff --git a/test/lisp/filenotify-tests.el b/test/lisp/filenotify-tests.el index 54e7ebfc0e..9b5c751021 100644 --- a/test/lisp/filenotify-tests.el +++ b/test/lisp/filenotify-tests.el @@ -425,6 +425,7 @@ file-notify--test-make-temp-name '(change) #'second-callback))) ;; Remove first watch. (file-notify-rm-watch file-notify--test-desc) + (file-notify--test-read-event) ;; Only the second callback shall run. (delete-file file-notify--test-tmpfile) (file-notify--wait-for-eventsNo, it still fails.
You're on the right track, however. The following patch does fix the problem:
--- a/test/lisp/filenotify-tests.el +++ b/test/lisp/filenotify-tests.el @@ -425,6 +425,7 @@ file-notify--test-make-temp-name '(change) #'second-callback))) ;; Remove first watch. (file-notify-rm-watch file-notify--test-desc) + (sit-for 0.1) ;; Only the second callback shall run. (delete-file file-notify--test-tmpfile) (file-notify--wait-for-events Ken
[Prev in Thread] | Current Thread | [Next in Thread] |