]> git.eshelyaron.com Git - emacs.git/commitdiff
Further work on emba tests
authorMichael Albinus <michael.albinus@gmx.de>
Mon, 7 Jan 2019 11:21:58 +0000 (12:21 +0100)
committerMichael Albinus <michael.albinus@gmx.de>
Mon, 7 Jan 2019 11:21:58 +0000 (12:21 +0100)
* .gitlab-ci.yml (test-all): Remove after_script.
(test-filenotify-gio): Remove after_script and when.  Add
src/gfilenotify.c as dependent change.  Use filenotify-tests.log
make target.

* 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): Check just for
(getenv "EMACS_EMBA_CI").

.gitlab-ci.yml
test/lisp/filenotify-tests.el

index 76f57e9c93942d601ef26aec59cff97a99f9cbae..876f64df740e18c818b1fb3a8801f23317a7d3f4 100644 (file)
@@ -38,6 +38,7 @@ stages:
   - test
 
 test-all:
+  # This tests also file monitor libraries inotify and inotifywatch.
   stage: test
   script:
     - DEBIAN_FRONTEND=noninteractive apt install --no-install-recommends -y -qq -o=Dpkg::Use-Pty=0 inotify-tools
@@ -45,22 +46,19 @@ test-all:
     - ./configure --without-makeinfo
     - make bootstrap
     - make check-expensive
-  after_script:
-    - DEBIAN_FRONTEND=noninteractive apt remove --no-install-recommends -y -qq -o=Dpkg::Use-Pty=0 inotify-tools
 
 test-filenotify-gio:
   stage: test
-  when: always
+  # This tests file monitor libraries gfilemonitor and gio.
   only:
     changes:
       - .gitlab-ci.yml
       - lisp/filenotify.el
+      - src/gfilenotify.c
       - test/lisp/filenotify-tests.el
   script:
     - DEBIAN_FRONTEND=noninteractive apt install --no-install-recommends -y -qq -o=Dpkg::Use-Pty=0 libglib2.0-dev libglib2.0-bin libglib2.0-0
     - ./autogen.sh autoconf
     - ./configure --without-makeinfo --with-file-notification=gfile
     - make bootstrap
-    - make -C test filenotify-tests
-  after_script:
-    - DEBIAN_FRONTEND=noninteractive apt remove --no-install-recommends -y -qq -o=Dpkg::Use-Pty=0 libglib2.0-dev libglib2.0-bin libglib2.0-0
+    - make -C test filenotify-tests.log
index b74d939519fb3b4e9fd5cbbc2104e28f96069fee..2aa0b6a0e8b174943e00b12d7bc51e66af192190 100644 (file)
@@ -688,10 +688,9 @@ delivered."
              '(created deleted stopped))
             ((string-equal (file-notify--test-library) "kqueue")
              '(created changed deleted stopped))
-             ;; inotify on emba does not detect `deleted' and
-             ;; `stopped' events of the directory.
-             ((and (string-match "inotify" (file-notify--test-library))
-                   (getenv "EMACS_EMBA_CI"))
+             ;; On emba, `deleted' and `stopped' events of the
+             ;; directory are not detected.
+             ((getenv "EMACS_EMBA_CI")
               '(created changed deleted))
             (t '(created changed deleted deleted stopped)))
          (write-region
@@ -738,10 +737,9 @@ delivered."
              '(created created changed changed deleted stopped))
             ((string-equal (file-notify--test-library) "kqueue")
              '(created changed created changed deleted stopped))
-             ;; inotify on emba does not detect `deleted' and
-             ;; `stopped' events of the directory.
-             ((and (string-match "inotify" (file-notify--test-library))
-                   (getenv "EMACS_EMBA_CI"))
+             ;; On emba, `deleted' and `stopped' events of the
+             ;; directory are not detected.
+             ((getenv "EMACS_EMBA_CI")
               '(created changed created changed deleted deleted))
             (t '(created changed created changed
                  deleted deleted deleted stopped)))
@@ -795,10 +793,9 @@ delivered."
              '(created created deleted deleted stopped))
             ((string-equal (file-notify--test-library) "kqueue")
              '(created changed renamed deleted stopped))
-             ;; inotify on emba does not detect `deleted' and
-             ;; `stopped' events of the directory.
-             ((and (string-match "inotify" (file-notify--test-library))
-                   (getenv "EMACS_EMBA_CI"))
+             ;; On emba, `deleted' and `stopped' events of the
+             ;; directory are not detected.
+             ((getenv "EMACS_EMBA_CI")
               '(created changed renamed deleted))
             (t '(created changed renamed deleted deleted stopped)))
          (write-region
@@ -1017,10 +1014,8 @@ delivered."
     ;; Cleanup.
     (file-notify--test-cleanup))
 
-  ;; inotify on emba does not detect `deleted' and
-  ;; `stopped' events of the directory.
-  (unless (and (string-match "inotify" (file-notify--test-library))
-               (getenv "EMACS_EMBA_CI"))
+  ;; On emba, `deleted' and `stopped' events of the directory are not detected.
+  (unless (getenv "EMACS_EMBA_CI")
     (unwind-protect
         (let ((file-notify--test-tmpdir
               (make-temp-file "file-notify-test-parent" t)))
@@ -1104,10 +1099,8 @@ delivered."
     ;; Cleanup.
     (file-notify--test-cleanup))
 
-  ;; inotify on emba does not detect `deleted' and
-  ;; `stopped' events of the directory.
-  (unless (and (string-match "inotify" (file-notify--test-library))
-               (getenv "EMACS_EMBA_CI"))
+  ;; On emba, `deleted' and `stopped' events of the directory are not detected.
+  (unless (getenv "EMACS_EMBA_CI")
     (unwind-protect
         (progn
          (should
@@ -1199,8 +1192,7 @@ delivered."
             (delete-file file)))
         (delete-directory file-notify--test-tmpfile)
         (if (or (string-equal (file-notify--test-library) "w32notify")
-                (and (string-match "inotify" (file-notify--test-library))
-                     (getenv "EMACS_EMBA_CI")))
+                (getenv "EMACS_EMBA_CI"))
             (file-notify--rm-descriptor file-notify--test-desc))
 
         ;; The environment shall be cleaned up.
@@ -1409,20 +1401,17 @@ the file watch."
                  ;; w32notify does not raise `deleted' and `stopped'
                  ;; events for the watched directory.
                   ((string-equal (file-notify--test-library) "w32notify") '())
-                  ;; inotify on emba does not detect `deleted' and
-                  ;; `stopped' events of the directory.
-                  ((and (string-match "inotify" (file-notify--test-library))
-                        (getenv "EMACS_EMBA_CI"))
+                  ;; On emba, `deleted' and `stopped' events of the
+                  ;; directory are not detected.
+                  ((getenv "EMACS_EMBA_CI")
                    '())
                   (t '(deleted stopped))))))
           (delete-directory file-notify--test-tmpfile 'recursive))
-        (unless (and (string-match "inotify" (file-notify--test-library))
-                     (getenv "EMACS_EMBA_CI"))
+        (unless (getenv "EMACS_EMBA_CI")
           (should-not (file-notify-valid-p file-notify--test-desc1))
           (should-not (file-notify-valid-p file-notify--test-desc2)))
         (when (or (string-equal (file-notify--test-library) "w32notify")
-                  (and (string-match "inotify" (file-notify--test-library))
-                       (getenv "EMACS_EMBA_CI")))
+                  (getenv "EMACS_EMBA_CI"))
           (file-notify--rm-descriptor file-notify--test-desc1)
           (file-notify--rm-descriptor file-notify--test-desc2))