diff options
| author | Michael Albinus | 2019-01-07 14:04:17 +0100 |
|---|---|---|
| committer | Michael Albinus | 2019-01-07 14:04:17 +0100 |
| commit | 536e6dea0f9302ef69d1bb12d0efc852c630d1ca (patch) | |
| tree | badaa709b19157d540ffba6516c05c3a7bdd5660 | |
| parent | 8acb88c5026cb11cbff466f53bef9d3e864879e7 (diff) | |
| download | emacs-536e6dea0f9302ef69d1bb12d0efc852c630d1ca.tar.gz emacs-536e6dea0f9302ef69d1bb12d0efc852c630d1ca.zip | |
Adapt tests for emba
* test/lisp/filenotify-tests.el (file-notify-test03-events)
(file-notify-test05-file-validity)
(file-notify-test06-dir-validity)
(file-notify-test07-many-events)
(file-notify-test09-watched-file-in-watched-dir): Adapt tests for emba.
| -rw-r--r-- | test/lisp/filenotify-tests.el | 49 |
1 files changed, 19 insertions, 30 deletions
diff --git a/test/lisp/filenotify-tests.el b/test/lisp/filenotify-tests.el index 4be51afb47f..fdc8d00d86d 100644 --- a/test/lisp/filenotify-tests.el +++ b/test/lisp/filenotify-tests.el | |||
| @@ -688,10 +688,9 @@ delivered." | |||
| 688 | '(created deleted stopped)) | 688 | '(created deleted stopped)) |
| 689 | ((string-equal (file-notify--test-library) "kqueue") | 689 | ((string-equal (file-notify--test-library) "kqueue") |
| 690 | '(created changed deleted stopped)) | 690 | '(created changed deleted stopped)) |
| 691 | ;; inotify on emba does not detect `deleted' and | 691 | ;; On emba, `deleted' and `stopped' events of the |
| 692 | ;; `stopped' events of the directory. | 692 | ;; directory are not detected. |
| 693 | ((and (string-equal (file-notify--test-library) "inotify") | 693 | ((getenv "EMACS_EMBA_CI") |
| 694 | (getenv "EMACS_EMBA_CI")) | ||
| 695 | '(created changed deleted)) | 694 | '(created changed deleted)) |
| 696 | (t '(created changed deleted deleted stopped))) | 695 | (t '(created changed deleted deleted stopped))) |
| 697 | (write-region | 696 | (write-region |
| @@ -738,10 +737,9 @@ delivered." | |||
| 738 | '(created created changed changed deleted stopped)) | 737 | '(created created changed changed deleted stopped)) |
| 739 | ((string-equal (file-notify--test-library) "kqueue") | 738 | ((string-equal (file-notify--test-library) "kqueue") |
| 740 | '(created changed created changed deleted stopped)) | 739 | '(created changed created changed deleted stopped)) |
| 741 | ;; inotify on emba does not detect `deleted' and | 740 | ;; On emba, `deleted' and `stopped' events of the |
| 742 | ;; `stopped' events of the directory. | 741 | ;; directory are not detected. |
| 743 | ((and (string-equal (file-notify--test-library) "inotify") | 742 | ((getenv "EMACS_EMBA_CI") |
| 744 | (getenv "EMACS_EMBA_CI")) | ||
| 745 | '(created changed created changed deleted deleted)) | 743 | '(created changed created changed deleted deleted)) |
| 746 | (t '(created changed created changed | 744 | (t '(created changed created changed |
| 747 | deleted deleted deleted stopped))) | 745 | deleted deleted deleted stopped))) |
| @@ -795,10 +793,9 @@ delivered." | |||
| 795 | '(created created deleted deleted stopped)) | 793 | '(created created deleted deleted stopped)) |
| 796 | ((string-equal (file-notify--test-library) "kqueue") | 794 | ((string-equal (file-notify--test-library) "kqueue") |
| 797 | '(created changed renamed deleted stopped)) | 795 | '(created changed renamed deleted stopped)) |
| 798 | ;; inotify on emba does not detect `deleted' and | 796 | ;; On emba, `deleted' and `stopped' events of the |
| 799 | ;; `stopped' events of the directory. | 797 | ;; directory are not detected. |
| 800 | ((and (string-equal (file-notify--test-library) "inotify") | 798 | ((getenv "EMACS_EMBA_CI") |
| 801 | (getenv "EMACS_EMBA_CI")) | ||
| 802 | '(created changed renamed deleted)) | 799 | '(created changed renamed deleted)) |
| 803 | (t '(created changed renamed deleted deleted stopped))) | 800 | (t '(created changed renamed deleted deleted stopped))) |
| 804 | (write-region | 801 | (write-region |
| @@ -1017,10 +1014,8 @@ delivered." | |||
| 1017 | ;; Cleanup. | 1014 | ;; Cleanup. |
| 1018 | (file-notify--test-cleanup)) | 1015 | (file-notify--test-cleanup)) |
| 1019 | 1016 | ||
| 1020 | ;; inotify on emba does not detect `deleted' and | 1017 | ;; On emba, `deleted' and `stopped' events of the directory are not detected. |
| 1021 | ;; `stopped' events of the directory. | 1018 | (unless (getenv "EMACS_EMBA_CI") |
| 1022 | (unless (and (string-equal (file-notify--test-library) "inotify") | ||
| 1023 | (getenv "EMACS_EMBA_CI")) | ||
| 1024 | (unwind-protect | 1019 | (unwind-protect |
| 1025 | (let ((file-notify--test-tmpdir | 1020 | (let ((file-notify--test-tmpdir |
| 1026 | (make-temp-file "file-notify-test-parent" t))) | 1021 | (make-temp-file "file-notify-test-parent" t))) |
| @@ -1104,10 +1099,8 @@ delivered." | |||
| 1104 | ;; Cleanup. | 1099 | ;; Cleanup. |
| 1105 | (file-notify--test-cleanup)) | 1100 | (file-notify--test-cleanup)) |
| 1106 | 1101 | ||
| 1107 | ;; inotify on emba does not detect `deleted' and | 1102 | ;; On emba, `deleted' and `stopped' events of the directory are not detected. |
| 1108 | ;; `stopped' events of the directory. | 1103 | (unless (getenv "EMACS_EMBA_CI") |
| 1109 | (unless (and (string-equal (file-notify--test-library) "inotify") | ||
| 1110 | (getenv "EMACS_EMBA_CI")) | ||
| 1111 | (unwind-protect | 1104 | (unwind-protect |
| 1112 | (progn | 1105 | (progn |
| 1113 | (should | 1106 | (should |
| @@ -1199,8 +1192,7 @@ delivered." | |||
| 1199 | (delete-file file))) | 1192 | (delete-file file))) |
| 1200 | (delete-directory file-notify--test-tmpfile) | 1193 | (delete-directory file-notify--test-tmpfile) |
| 1201 | (if (or (string-equal (file-notify--test-library) "w32notify") | 1194 | (if (or (string-equal (file-notify--test-library) "w32notify") |
| 1202 | (and (string-equal (file-notify--test-library) "inotify") | 1195 | (getenv "EMACS_EMBA_CI")) |
| 1203 | (getenv "EMACS_EMBA_CI"))) | ||
| 1204 | (file-notify--rm-descriptor file-notify--test-desc)) | 1196 | (file-notify--rm-descriptor file-notify--test-desc)) |
| 1205 | 1197 | ||
| 1206 | ;; The environment shall be cleaned up. | 1198 | ;; The environment shall be cleaned up. |
| @@ -1409,20 +1401,17 @@ the file watch." | |||
| 1409 | ;; w32notify does not raise `deleted' and `stopped' | 1401 | ;; w32notify does not raise `deleted' and `stopped' |
| 1410 | ;; events for the watched directory. | 1402 | ;; events for the watched directory. |
| 1411 | ((string-equal (file-notify--test-library) "w32notify") '()) | 1403 | ((string-equal (file-notify--test-library) "w32notify") '()) |
| 1412 | ;; inotify on emba does not detect `deleted' and | 1404 | ;; On emba, `deleted' and `stopped' events of the |
| 1413 | ;; `stopped' events of the directory. | 1405 | ;; directory are not detected. |
| 1414 | ((and (string-equal (file-notify--test-library) "inotify") | 1406 | ((getenv "EMACS_EMBA_CI") |
| 1415 | (getenv "EMACS_EMBA_CI")) | ||
| 1416 | '()) | 1407 | '()) |
| 1417 | (t '(deleted stopped)))))) | 1408 | (t '(deleted stopped)))))) |
| 1418 | (delete-directory file-notify--test-tmpfile 'recursive)) | 1409 | (delete-directory file-notify--test-tmpfile 'recursive)) |
| 1419 | (unless (and (string-equal (file-notify--test-library) "inotify") | 1410 | (unless (getenv "EMACS_EMBA_CI") |
| 1420 | (getenv "EMACS_EMBA_CI")) | ||
| 1421 | (should-not (file-notify-valid-p file-notify--test-desc1)) | 1411 | (should-not (file-notify-valid-p file-notify--test-desc1)) |
| 1422 | (should-not (file-notify-valid-p file-notify--test-desc2))) | 1412 | (should-not (file-notify-valid-p file-notify--test-desc2))) |
| 1423 | (when (or (string-equal (file-notify--test-library) "w32notify") | 1413 | (when (or (string-equal (file-notify--test-library) "w32notify") |
| 1424 | (and (string-equal (file-notify--test-library) "inotify") | 1414 | (getenv "EMACS_EMBA_CI")) |
| 1425 | (getenv "EMACS_EMBA_CI"))) | ||
| 1426 | (file-notify--rm-descriptor file-notify--test-desc1) | 1415 | (file-notify--rm-descriptor file-notify--test-desc1) |
| 1427 | (file-notify--rm-descriptor file-notify--test-desc2)) | 1416 | (file-notify--rm-descriptor file-notify--test-desc2)) |
| 1428 | 1417 | ||