]> git.eshelyaron.com Git - emacs.git/commitdiff
; Improve tramp-tests traces
authorMichael Albinus <michael.albinus@gmx.de>
Thu, 13 Jul 2017 14:40:07 +0000 (16:40 +0200)
committerMichael Albinus <michael.albinus@gmx.de>
Thu, 13 Jul 2017 14:40:07 +0000 (16:40 +0200)
test/Makefile.in
test/lisp/net/tramp-tests.el

index 11373db8ca96dd011f2d2988f893fe39de7fe764..4e1a120d5c26c5f4218319fe07c8f518520f01e6 100644 (file)
@@ -136,7 +136,8 @@ endif
        $(AM_V_ELC)$(emacs) -f batch-byte-compile $<
 
 ## Save logs, and show logs for failed tests.
-WRITE_LOG = > $@ 2>&1 || { STAT=$$?; cat $@; exit $$STAT; }
+WRITE_LOG = $(if $(and ${NIX_STORE}, $(findstring tramp, $@)), |& tee $@, > $@ 2>&1) \
+               || { STAT=$$?; cat $@; exit $$STAT; }
 
 ifeq ($(TEST_LOAD_EL), yes)
 testloadfile = $*.el
@@ -147,8 +148,7 @@ endif
 %.log: %.elc
        $(AM_V_at)${MKDIR_P} $(dir $@)
        $(AM_V_GEN)HOME=/nonexistent $(emacs) -l ert -l $(testloadfile) \
-         --eval "(ert-run-tests-batch-and-exit ${SELECTOR_ACTUAL})" \
-         $(if $(and ${NIX_STORE}, $(findstring tramp, $(testloadfile))), , ${WRITE_LOG})
+         --eval "(ert-run-tests-batch-and-exit ${SELECTOR_ACTUAL})" ${WRITE_LOG}
 
 ifeq (@HAVE_MODULES@, yes)
 maybe_exclude_module_tests :=
index 8001d9433a0557219b547f406b5c926cc1471129..263e1359066ee9aef81a11d4a5a143cb81746d24 100644 (file)
@@ -3787,9 +3787,15 @@ process sentinels.  They shall not disturb each other."
                       (should-not (file-attributes file))
                     (should (file-attributes file)))
                   ;; Send string to process.
+                  (tramp--test-message
+                   "Trace 1 action %d %s %s" count buf (current-time-string))
                   (process-send-string proc (format "%s\n" (buffer-name buf)))
+                  (tramp--test-message
+                   "Trace 2 action %d %s %s" count buf (current-time-string))
                   (accept-process-output proc 0.1 nil 0)
                   ;; Regular operation.
+                  (tramp--test-message
+                   "Trace 3 action %d %s %s" count buf (current-time-string))
                   (if (= count 2)
                       (should-not (file-attributes file))
                     (should (file-attributes file)))