1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-15 18:40:39 -08:00

; even less test log spam from load

This commit is contained in:
Mattias Engdegård 2025-09-11 22:21:57 +02:00
parent 0bf5898f20
commit 464216ca73
4 changed files with 12 additions and 11 deletions

View file

@ -885,8 +885,9 @@ byte-compiled. Run with dynamic binding."
(s-comp (byte-compile s-int))
(v-int (lambda (x) (1+ x)))
(v-comp (byte-compile v-int))
(bc (lambda (f) (bytecomp-tests--with-warnings (byte-compile f))))
(comp (lambda (f) (funcall (funcall bc `(lambda () (,f 3)))))))
(comp (lambda (f)
(funcall (bytecomp-tests--with-warnings
(byte-compile `(lambda () (,f 3))))))))
(should (equal (funcall comp s-int) 4))
(should (equal (funcall comp s-comp) 4))
(should (equal (funcall comp v-int) 4))
@ -1466,7 +1467,7 @@ literals (Bug#20852)."
(print form (current-buffer)))
(write-region (point-min) (point-max) source nil 'silent)
(byte-compile-file source)
(load source)
(load source nil t)
(should (equal bytecomp-tests--foobar (cons 1 2)))))
(ert-deftest bytecomp-tests--test-no-warnings-with-advice ()
@ -1988,7 +1989,7 @@ compiled correctly."
(let ((file (ert-resource-file "bc-test-alpha.el"))
(load-path (cons (ert-resource-directory) load-path)))
(byte-compile-file file)
(load-file (concat file "c"))
(load (concat file "c") nil t t)
(should (equal (bc-test-alpha-f 'a) '(nil a)))))
(ert-deftest bytecomp-tests-byte-compile--wide-docstring-p/func-arg-list ()

View file

@ -66,7 +66,7 @@
;; Test the case where we load a file which byte-compiles another.
(defvar macroexp--m1-tests-comp-filename)
(makunbound 'macroexp--m1-tests-comp-filename)
(load (expand-file-name "m2.el" rsrc-dir))
(load (expand-file-name "m2.el" rsrc-dir) nil t)
(should (equal "m1.el"
(file-name-nondirectory macroexp--m1-tests-comp-filename)))))

View file

@ -1079,7 +1079,7 @@ evaluation of BODY."
(mapatoms (lambda (s)
(when (string-match "^elisp--foo-" (symbol-name s))
(unintern s obarray))))
(load test-file)
(load test-file nil t)
(should (intern-soft "elisp--foo-test"))
(should-not (intern-soft "f-test"))))
@ -1094,13 +1094,13 @@ evaluation of BODY."
(should-not (intern-soft "f-test"))
(should (intern-soft "elisp--foo-test"))
(should-not (fboundp (intern-soft "elisp--foo-test")))
(load byte-compiled)
(load byte-compiled nil t)
(should (intern-soft "elisp--foo-test"))
(should-not (intern-soft "f-test"))))
(ert-deftest elisp-shorthand-completion-at-point ()
(let ((test-file (ert-resource-file "simple-shorthand-test.el")))
(load test-file)
(load test-file nil t)
(with-current-buffer (find-file-noselect test-file)
(revert-buffer t t)
(goto-char (point-min))
@ -1115,7 +1115,7 @@ evaluation of BODY."
(ert-deftest elisp-shorthand-escape ()
(let ((test-file (ert-resource-file "simple-shorthand-test.el")))
(load test-file)
(load test-file nil t)
(should (intern-soft "f-test4---"))
(should-not (intern-soft "elisp--foo-test4---"))
(should (= 84 (funcall (intern-soft "f-test4---"))))

View file

@ -388,14 +388,14 @@ literals (Bug#20852)."
;; but eagerly with `force-load-doc-strings' set.
(let ((file (expand-file-name "lazydoc.el" (ert-resource-directory))))
(fmakunbound 'lazydoc-fun)
(load file)
(load file nil t)
(let ((f (symbol-function 'lazydoc-fun)))
(should (byte-code-function-p f))
(should (equal (aref f 4) (cons file 87))))
(fmakunbound 'lazydoc-fun)
(let ((load-force-doc-strings t))
(load file)
(load file nil t)
(let ((f (symbol-function 'lazydoc-fun)))
(should (byte-code-function-p f))
(should (equal (aref f 4) "My little\ndoc string\nhere"))))))