summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/infra/gitlab-ci.yml22
-rw-r--r--test/lisp/cedet/semantic-utest.el2
-rw-r--r--test/lisp/comint-tests.el16
-rw-r--r--test/lisp/emacs-lisp/comp-tests.el55
-rw-r--r--test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el2
-rw-r--r--test/lisp/emacs-lisp/subr-x-tests.el11
-rw-r--r--test/lisp/erc/erc-join-tests.el2
-rw-r--r--test/lisp/eshell/esh-arg-tests.el105
-rw-r--r--test/lisp/eshell/eshell-tests.el31
-rw-r--r--test/lisp/filenotify-tests.el4
-rw-r--r--test/lisp/gnus/mml-sec-tests.el2
-rw-r--r--test/lisp/international/ucs-normalize-tests.el103
-rw-r--r--test/lisp/net/tramp-archive-tests.el2
-rw-r--r--test/lisp/net/tramp-tests.el12
-rw-r--r--test/lisp/progmodes/project-tests.el29
-rw-r--r--test/lisp/progmodes/python-tests.el113
-rw-r--r--test/lisp/server-tests.el14
-rw-r--r--test/manual/cedet/cedet-utests.el3
-rw-r--r--test/manual/cedet/semantic-tests.el3
-rw-r--r--test/manual/cedet/tests/testpolymorph.cpp10
-rw-r--r--test/manual/cedet/tests/testsppreplace.c4
-rw-r--r--test/manual/cedet/tests/testsppreplaced.c4
-rw-r--r--test/src/sqlite-tests.el1
-rw-r--r--test/src/treesit-tests.el8
24 files changed, 396 insertions, 162 deletions
diff --git a/test/infra/gitlab-ci.yml b/test/infra/gitlab-ci.yml
index e034430edce..64b47eb7e47 100644
--- a/test/infra/gitlab-ci.yml
+++ b/test/infra/gitlab-ci.yml
@@ -155,7 +155,7 @@ default:
.filenotify-gio-template:
rules:
- if: '$CI_PIPELINE_SOURCE == "web"'
- - if: '$CI_PIPELINE_SOURCE == "schedule"'
+ # - if: '$CI_PIPELINE_SOURCE == "schedule"'
changes:
- "**.in"
- lisp/autorevert.el
@@ -252,17 +252,17 @@ build-native-comp-speed0:
variables:
target: emacs-native-comp-speed0
-build-native-comp-speed1:
- stage: native-comp-images
- extends: [.job-template, .build-template, .native-comp-template]
- variables:
- target: emacs-native-comp-speed1
+# build-native-comp-speed1:
+# stage: native-comp-images
+# extends: [.job-template, .build-template, .native-comp-template]
+# variables:
+# target: emacs-native-comp-speed1
-build-native-comp-speed2:
- stage: native-comp-images
- extends: [.job-template, .build-template, .native-comp-template]
- variables:
- target: emacs-native-comp-speed2
+# build-native-comp-speed2:
+# stage: native-comp-images
+# extends: [.job-template, .build-template, .native-comp-template]
+# variables:
+# target: emacs-native-comp-speed2
test-native-comp-speed0:
stage: native-comp
diff --git a/test/lisp/cedet/semantic-utest.el b/test/lisp/cedet/semantic-utest.el
index b577b198089..4aaa4c5e3c4 100644
--- a/test/lisp/cedet/semantic-utest.el
+++ b/test/lisp/cedet/semantic-utest.el
@@ -593,7 +593,7 @@ INSERTME is the text to be inserted after the deletion."
)
(ert-deftest semantic-utest-Scheme()
- (skip-unless nil) ;; There is a bug w/ scheme parser. Skip this for now.
+ (skip-unless nil) ;; There is a bug with scheme parser. Skip this for now.
(semantic-utest-generic (semantic-utest-fname "tst.scm") semantic-utest-Scheme-buffer-contents semantic-utest-Scheme-name-contents '("fun2") ";1" ";deleted line")
)
diff --git a/test/lisp/comint-tests.el b/test/lisp/comint-tests.el
index 8402c13daf3..ce1a6865b65 100644
--- a/test/lisp/comint-tests.el
+++ b/test/lisp/comint-tests.el
@@ -59,9 +59,23 @@
(dolist (str comint-testsuite-password-strings)
(should (string-match comint-password-prompt-regexp str))))
+(declare-function w32-application-type "w32proc.c")
+(defun w32-native-executable-p (fname)
+ "Predicate to test program FNAME for being a native Windows application."
+ (and (memq (w32-application-type fname) '(w32-native dos))
+ (file-executable-p fname)))
+
+(defun w32-native-executable-find (name)
+ "Find a native MS-Windows application named NAME.
+This is needed to avoid invoking MSYS or Cygwin executables that
+happen to lurk on PATH when running the test suite."
+ (locate-file name exec-path exec-suffixes 'w32-native-executable-p))
+
(defun comint-tests/test-password-function (password-function)
"PASSWORD-FUNCTION can return nil or a string."
- (when-let ((cat (executable-find "cat")))
+ (when-let ((cat (if (eq system-type 'windows-nt)
+ (w32-native-executable-find "cat")
+ (executable-find "cat"))))
(let ((comint-password-function password-function))
(cl-letf (((symbol-function 'read-passwd)
(lambda (&rest _args) "non-nil")))
diff --git a/test/lisp/emacs-lisp/comp-tests.el b/test/lisp/emacs-lisp/comp-tests.el
index 082b641fe30..418c7296948 100644
--- a/test/lisp/emacs-lisp/comp-tests.el
+++ b/test/lisp/emacs-lisp/comp-tests.el
@@ -31,25 +31,30 @@
(defmacro with-test-native-compile-prune-cache (&rest body)
(declare (indent 0) (debug t))
`(ert-with-temp-directory testdir
- (setq testdir (expand-file-name "eln-cache" testdir))
- (make-directory testdir)
- (let* ((c1 (expand-file-name "29.0.50-cur" testdir))
- (c2 (expand-file-name "29.0.50-old" testdir))
- (native-comp-eln-load-path (list testdir))
- (comp-native-version-dir "29.0.50-cur"))
- (dolist (d (list c1 c2))
- (make-directory d)
- (with-temp-file (expand-file-name "some.eln" d) (insert "foo"))
- (with-temp-file (expand-file-name "some.eln.tmp" d) (insert "foo")))
- ,@body)))
+ (let ((usr-cache (expand-file-name "eln-usr-cache" testdir))
+ (sys-cache (expand-file-name "eln-sys-cache" testdir)))
+ (make-directory usr-cache)
+ (make-directory sys-cache)
+ (let* ((c1 (expand-file-name "29.0.50-cur" usr-cache))
+ (c2 (expand-file-name "29.0.50-old" usr-cache))
+ (s1 (expand-file-name "29.0.50-cur" sys-cache))
+ (s2 (expand-file-name "preloaded" s1))
+ (native-comp-eln-load-path (list usr-cache sys-cache))
+ (comp-native-version-dir "29.0.50-cur"))
+ (dolist (d (list c1 c2 s1 s2))
+ (make-directory d)
+ (with-temp-file (expand-file-name "some.eln" d) (insert "foo"))
+ (with-temp-file (expand-file-name "some.eln.tmp" d) (insert "foo")))
+ ,@body))))
(ert-deftest test-native-compile-prune-cache ()
(skip-unless (featurep 'native-compile))
(with-test-native-compile-prune-cache
(native-compile-prune-cache)
- (should (file-directory-p c1))
- (should (file-regular-p (expand-file-name "some.eln" c1)))
- (should (file-regular-p (expand-file-name "some.eln.tmp" c1)))
+ (dolist (d (list c1 s1 s2))
+ (should (file-directory-p d))
+ (should (file-regular-p (expand-file-name "some.eln" d)))
+ (should (file-regular-p (expand-file-name "some.eln.tmp" d))))
(should-not (file-directory-p c2))
(should-not (file-regular-p (expand-file-name "some.eln" c2)))
(should-not (file-regular-p (expand-file-name "some.eln.tmp" c2)))))
@@ -57,21 +62,23 @@
(ert-deftest test-native-compile-prune-cache/delete-only-eln ()
(skip-unless (featurep 'native-compile))
(with-test-native-compile-prune-cache
- (with-temp-file (expand-file-name "keep1.txt" c1) (insert "foo"))
- (with-temp-file (expand-file-name "keep2.txt" c2) (insert "foo"))
+ (dolist (d (list c1 c2 s1 s2))
+ (with-temp-file (expand-file-name "keep.txt" d) (insert "foo")))
(native-compile-prune-cache)
- (should (file-regular-p (expand-file-name "keep1.txt" c1)))
- (should (file-regular-p (expand-file-name "keep2.txt" c2)))))
+ (dolist (d (list c1 c2 s1 s2))
+ (should (file-regular-p (expand-file-name "keep.txt" d))))))
(ert-deftest test-native-compile-prune-cache/dont-delete-in-parent-of-cache ()
(skip-unless (featurep 'native-compile))
(with-test-native-compile-prune-cache
- (let ((f1 (expand-file-name "../some.eln" testdir))
- (f2 (expand-file-name "some.eln" testdir)))
- (with-temp-file f1 (insert "foo"))
- (with-temp-file f2 (insert "foo"))
+ (let ((f1 (expand-file-name "../some.eln" usr-cache))
+ (f2 (expand-file-name "some.eln" usr-cache))
+ (f3 (expand-file-name "../some.eln" sys-cache))
+ (f4 (expand-file-name "some.eln" sys-cache)))
+ (dolist (f (list f1 f2 f3 f4))
+ (with-temp-file f (insert "foo")))
(native-compile-prune-cache)
- (should (file-regular-p f1))
- (should (file-regular-p f2)))))
+ (dolist (f (list f1 f2 f3 f4))
+ (should (file-regular-p f))))))
;;; comp-tests.el ends here
diff --git a/test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el b/test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el
index af19c122b9f..05d24a8e35d 100644
--- a/test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el
+++ b/test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el
@@ -308,7 +308,7 @@
(setq eieio-test-method-order-list (nreverse eieio-test-method-order-list))
(eieio-test-match ans)))
-;;; Jan's methodinvoke order w/ multiple inheritance and :after methods.
+;;; Jan's methodinvoke order with multiple inheritance and :after methods.
;;
(defclass eitest-Ja ()
())
diff --git a/test/lisp/emacs-lisp/subr-x-tests.el b/test/lisp/emacs-lisp/subr-x-tests.el
index 7a3efe9db62..e80d2e17e8d 100644
--- a/test/lisp/emacs-lisp/subr-x-tests.el
+++ b/test/lisp/emacs-lisp/subr-x-tests.el
@@ -707,7 +707,16 @@
(should (equal (get-text-property 2 'display) '(raise 0.5)))
(should (equal (get-text-property 5 'display)
[(raise 0.5) (height 2.0)]))
- (should (equal (get-text-property 9 'display) '(raise 0.5)))))
+ (should (equal (get-text-property 9 'display) '(raise 0.5))))
+ (with-temp-buffer
+ (should (equal (let ((str "some useless string"))
+ (add-display-text-property 4 8 'height 2.0 str)
+ (add-display-text-property 2 12 'raise 0.5 str)
+ str)
+ #("some useless string"
+ 2 4 (display (raise 0.5))
+ 4 8 (display ((raise 0.5) (height 2.0)))
+ 8 12 (display (raise 0.5)))))))
(ert-deftest subr-x-named-let ()
(let ((funs ()))
diff --git a/test/lisp/erc/erc-join-tests.el b/test/lisp/erc/erc-join-tests.el
index 8210defbfbd..89521ba4292 100644
--- a/test/lisp/erc/erc-join-tests.el
+++ b/test/lisp/erc/erc-join-tests.el
@@ -335,7 +335,7 @@
(start-process "true" (current-buffer) "true")
erc-server-current-nick "tester"
erc-server-announced-name "foo.gnu.chat"
- ;; Assume special case w/o known network
+ ;; Assume special case without known network
erc-networks--id (make-erc-networks--id))
(set-process-query-on-exit-flag erc-server-process nil)
(should-not calls)
diff --git a/test/lisp/eshell/esh-arg-tests.el b/test/lisp/eshell/esh-arg-tests.el
new file mode 100644
index 00000000000..77f9404d4c7
--- /dev/null
+++ b/test/lisp/eshell/esh-arg-tests.el
@@ -0,0 +1,105 @@
+;;; esh-arg-tests.el --- esh-arg test suite -*- lexical-binding:t -*-
+
+;; Copyright (C) 2022 Free Software Foundation, Inc.
+
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software: you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>.
+
+;;; Commentary:
+
+;; Tests for Eshell's argument handling.
+
+;;; Code:
+
+(require 'ert)
+(require 'esh-mode)
+(require 'eshell)
+
+(require 'eshell-tests-helpers
+ (expand-file-name "eshell-tests-helpers"
+ (file-name-directory (or load-file-name
+ default-directory))))
+
+(defvar eshell-test-value nil)
+
+;;; Tests:
+
+(ert-deftest esh-arg-test/escape/nonspecial ()
+ "Test that \"\\c\" and \"c\" are equivalent when \"c\" is not a
+special character."
+ (with-temp-eshell
+ (eshell-match-command-output "echo he\\llo"
+ "hello\n")))
+
+(ert-deftest esh-arg-test/escape/nonspecial-unicode ()
+ "Test that \"\\c\" and \"c\" are equivalent when \"c\" is a
+unicode character (unicode characters are nonspecial by
+definition)."
+ (with-temp-eshell
+ (eshell-match-command-output "echo Vid\\éos"
+ "Vidéos\n")))
+
+(ert-deftest esh-arg-test/escape/special ()
+ "Test that the backslash is not preserved for escaped special
+chars."
+ (with-temp-eshell
+ (eshell-match-command-output "echo he\\\\llo"
+ ;; Backslashes are doubled for regexp.
+ "he\\\\llo\n")))
+
+(ert-deftest esh-arg-test/escape/newline ()
+ "Test that an escaped newline is equivalent to the empty string.
+When newlines are *nonspecial*, an escaped newline should be
+treated as just a newline."
+ (with-temp-eshell
+ (eshell-match-command-output "echo hi\\\nthere"
+ "hithere\n")))
+
+(ert-deftest esh-arg-test/escape/newline-conditional ()
+ "Test invocation of an if/else statement using line continuations."
+ (let ((eshell-test-value t))
+ (eshell-command-result-equal
+ "if $eshell-test-value \\\n{echo yes} \\\n{echo no}"
+ "yes"))
+ (let ((eshell-test-value nil))
+ (eshell-command-result-equal
+ "if $eshell-test-value \\\n{echo yes} \\\n{echo no}"
+ "no")))
+
+(ert-deftest esh-arg-test/escape-quoted/nonspecial ()
+ "Test that the backslash is preserved for escaped nonspecial
+chars."
+ (with-temp-eshell
+ (eshell-match-command-output "echo \"h\\i\""
+ ;; Backslashes are doubled for regexp.
+ "h\\\\i\n")))
+
+(ert-deftest esh-arg-test/escape-quoted/special ()
+ "Test that the backslash is not preserved for escaped special
+chars."
+ (with-temp-eshell
+ (eshell-match-command-output "echo \"\\\"hi\\\\\""
+ ;; Backslashes are doubled for regexp.
+ "\\\"hi\\\\\n")))
+
+(ert-deftest esh-arg-test/escape-quoted/newline ()
+ "Test that an escaped newline is equivalent to the empty string.
+When newlines are *nonspecial*, an escaped newline should be
+treated literally, as a backslash and a newline."
+ (with-temp-eshell
+ (eshell-match-command-output "echo \"hi\\\nthere\""
+ "hithere\n")))
+
+;; esh-arg-tests.el ends here
diff --git a/test/lisp/eshell/eshell-tests.el b/test/lisp/eshell/eshell-tests.el
index d5112146c2d..c67ac67fd36 100644
--- a/test/lisp/eshell/eshell-tests.el
+++ b/test/lisp/eshell/eshell-tests.el
@@ -105,37 +105,6 @@
(format template "format \"%s\" eshell-in-pipeline-p")
"nil")))
-(ert-deftest eshell-test/escape-nonspecial ()
- "Test that \"\\c\" and \"c\" are equivalent when \"c\" is not a
-special character."
- (with-temp-eshell
- (eshell-match-command-output "echo he\\llo"
- "hello\n")))
-
-(ert-deftest eshell-test/escape-nonspecial-unicode ()
- "Test that \"\\c\" and \"c\" are equivalent when \"c\" is a
-unicode character (unicode characters are nonspecial by
-definition)."
- (with-temp-eshell
- (eshell-match-command-output "echo Vid\\éos"
- "Vidéos\n")))
-
-(ert-deftest eshell-test/escape-nonspecial-quoted ()
- "Test that the backslash is preserved for escaped nonspecial
-chars"
- (with-temp-eshell
- (eshell-match-command-output "echo \"h\\i\""
- ;; Backslashes are doubled for regexp.
- "h\\\\i\n")))
-
-(ert-deftest eshell-test/escape-special-quoted ()
- "Test that the backslash is not preserved for escaped special
-chars"
- (with-temp-eshell
- (eshell-match-command-output "echo \"\\\"hi\\\\\""
- ;; Backslashes are doubled for regexp.
- "\\\"hi\\\\\n")))
-
(ert-deftest eshell-test/command-running-p ()
"Modeline should show no command running"
(with-temp-eshell
diff --git a/test/lisp/filenotify-tests.el b/test/lisp/filenotify-tests.el
index d82e2dae7aa..724cd63e222 100644
--- a/test/lisp/filenotify-tests.el
+++ b/test/lisp/filenotify-tests.el
@@ -1590,8 +1590,8 @@ the file watch."
(unwind-protect
(progn
(write-region "any text" nil file-notify--test-tmpfile1 nil 'no-message)
- ;; Some systems, like MS Windows w/o sufficient privileges, do
- ;; not allow creation of symbolic links.
+ ;; Some systems, like MS Windows without sufficient
+ ;; privileges, do not allow creation of symbolic links.
(condition-case nil
(make-symbolic-link
file-notify--test-tmpfile1 file-notify--test-tmpfile)
diff --git a/test/lisp/gnus/mml-sec-tests.el b/test/lisp/gnus/mml-sec-tests.el
index e4e607b70e6..f8ebf2f3a99 100644
--- a/test/lisp/gnus/mml-sec-tests.el
+++ b/test/lisp/gnus/mml-sec-tests.el
@@ -789,7 +789,7 @@ With Ma Gnus v0.14 and earlier a signature would be created with a wrong key."
;; TODO Passphrase passing and caching in Emacs does not seem to work
;; with gpgsm at all.
-;; Independently of caching settings, a pinentry dialogue is displayed.
+;; Independently of caching settings, a pinentry dialog is displayed.
;; Thus, the following tests require the user to enter the correct gpgsm
;; passphrases at the correct points in time. (Either empty string or
;; "Passphrase".)
diff --git a/test/lisp/international/ucs-normalize-tests.el b/test/lisp/international/ucs-normalize-tests.el
index 9e359d5022f..380140308aa 100644
--- a/test/lisp/international/ucs-normalize-tests.el
+++ b/test/lisp/international/ucs-normalize-tests.el
@@ -59,7 +59,7 @@ And NORM is one of the symbols `NFC', `NFD', `NFKC', `NFKD' for brevity."
(NFD . ucs-normalize-NFD-region)
(NFKC . ucs-normalize-NFKC-region)
(NFKD . ucs-normalize-NFKD-region))))
- `(with-current-buffer ucs-normalize-tests--norm-buf
+ `(progn
(erase-buffer)
(insert ,str)
(,(cdr (assq norm norm-alist)) (point-min) (point-max))
@@ -74,7 +74,7 @@ And NORM is one of the symbols `NFC', `NFD', `NFKC', `NFKD' for brevity."
(NFD . ucs-normalize-NFD-region)
(NFKC . ucs-normalize-NFKC-region)
(NFKD . ucs-normalize-NFKD-region))))
- `(with-current-buffer ucs-normalize-tests--norm-buf
+ `(progn
(erase-buffer)
(insert ,char)
(,(cdr (assq norm norm-alist)) (point-min) (point-max))
@@ -90,36 +90,37 @@ The following invariants must be true for all conformant implementations..."
;; See `ucs-normalize-tests--rule2-holds-p'.
(aset ucs-normalize-tests--chars-part1
(aref source 0) 1))
- (and
- ;; c2 == toNFC(c1) == toNFC(c2) == toNFC(c3)
- (ucs-normalize-tests--normalization-equal-p NFC source nfc)
- (ucs-normalize-tests--normalization-equal-p NFC nfc nfc)
- (ucs-normalize-tests--normalization-equal-p NFC nfd nfc)
- ;; c4 == toNFC(c4) == toNFC(c5)
- (ucs-normalize-tests--normalization-equal-p NFC nfkc nfkc)
- (ucs-normalize-tests--normalization-equal-p NFC nfkd nfkc)
-
- ;; c3 == toNFD(c1) == toNFD(c2) == toNFD(c3)
- (ucs-normalize-tests--normalization-equal-p NFD source nfd)
- (ucs-normalize-tests--normalization-equal-p NFD nfc nfd)
- (ucs-normalize-tests--normalization-equal-p NFD nfd nfd)
- ;; c5 == toNFD(c4) == toNFD(c5)
- (ucs-normalize-tests--normalization-equal-p NFD nfkc nfkd)
- (ucs-normalize-tests--normalization-equal-p NFD nfkd nfkd)
-
- ;; c4 == toNFKC(c1) == toNFKC(c2) == toNFKC(c3) == toNFKC(c4) == toNFKC(c5)
- (ucs-normalize-tests--normalization-equal-p NFKC source nfkc)
- (ucs-normalize-tests--normalization-equal-p NFKC nfc nfkc)
- (ucs-normalize-tests--normalization-equal-p NFKC nfd nfkc)
- (ucs-normalize-tests--normalization-equal-p NFKC nfkc nfkc)
- (ucs-normalize-tests--normalization-equal-p NFKC nfkd nfkc)
-
- ;; c5 == toNFKD(c1) == toNFKD(c2) == toNFKD(c3) == toNFKD(c4) == toNFKD(c5)
- (ucs-normalize-tests--normalization-equal-p NFKD source nfkd)
- (ucs-normalize-tests--normalization-equal-p NFKD nfc nfkd)
- (ucs-normalize-tests--normalization-equal-p NFKD nfd nfkd)
- (ucs-normalize-tests--normalization-equal-p NFKD nfkc nfkd)
- (ucs-normalize-tests--normalization-equal-p NFKD nfkd nfkd)))
+ (with-current-buffer ucs-normalize-tests--norm-buf
+ (and
+ ;; c2 == toNFC(c1) == toNFC(c2) == toNFC(c3)
+ (ucs-normalize-tests--normalization-equal-p NFC source nfc)
+ (ucs-normalize-tests--normalization-equal-p NFC nfc nfc)
+ (ucs-normalize-tests--normalization-equal-p NFC nfd nfc)
+ ;; c4 == toNFC(c4) == toNFC(c5)
+ (ucs-normalize-tests--normalization-equal-p NFC nfkc nfkc)
+ (ucs-normalize-tests--normalization-equal-p NFC nfkd nfkc)
+
+ ;; c3 == toNFD(c1) == toNFD(c2) == toNFD(c3)
+ (ucs-normalize-tests--normalization-equal-p NFD source nfd)
+ (ucs-normalize-tests--normalization-equal-p NFD nfc nfd)
+ (ucs-normalize-tests--normalization-equal-p NFD nfd nfd)
+ ;; c5 == toNFD(c4) == toNFD(c5)
+ (ucs-normalize-tests--normalization-equal-p NFD nfkc nfkd)
+ (ucs-normalize-tests--normalization-equal-p NFD nfkd nfkd)
+
+ ;; c4 == toNFKC(c1) == toNFKC(c2) == toNFKC(c3) == toNFKC(c4) == toNFKC(c5)
+ (ucs-normalize-tests--normalization-equal-p NFKC source nfkc)
+ (ucs-normalize-tests--normalization-equal-p NFKC nfc nfkc)
+ (ucs-normalize-tests--normalization-equal-p NFKC nfd nfkc)
+ (ucs-normalize-tests--normalization-equal-p NFKC nfkc nfkc)
+ (ucs-normalize-tests--normalization-equal-p NFKC nfkd nfkc)
+
+ ;; c5 == toNFKD(c1) == toNFKD(c2) == toNFKD(c3) == toNFKD(c4) == toNFKD(c5)
+ (ucs-normalize-tests--normalization-equal-p NFKD source nfkd)
+ (ucs-normalize-tests--normalization-equal-p NFKD nfc nfkd)
+ (ucs-normalize-tests--normalization-equal-p NFKD nfd nfkd)
+ (ucs-normalize-tests--normalization-equal-p NFKD nfkc nfkd)
+ (ucs-normalize-tests--normalization-equal-p NFKD nfkd nfkd))))
(defsubst ucs-normalize-tests--rule2-holds-p (X)
"Check 2nd conformance rule.
@@ -127,7 +128,9 @@ For every code point X assigned in this version of Unicode that
is not specifically listed in Part 1, the following invariants
must be true for all conformant implementations:
- X == toNFC(X) == toNFD(X) == toNFKC(X) == toNFKD(X)"
+ X == toNFC(X) == toNFD(X) == toNFKC(X) == toNFKD(X)
+
+Must be called with `ucs-normalize-tests--norm-buf' as current buffer."
(and (ucs-normalize-tests--normalization-chareq-p NFC X X)
(ucs-normalize-tests--normalization-chareq-p NFD X X)
(ucs-normalize-tests--normalization-chareq-p NFKC X X)
@@ -230,26 +233,30 @@ must be true for all conformant implementations:
(defun ucs-normalize-tests--part1-rule2 (chars-part1)
(let ((reporter (make-progress-reporter "UCS Normalize Test Part1, rule 2"
- 0 (max-char)))
- (failed-chars nil))
- (map-char-table
- (lambda (char-range listed-in-part)
- (unless (eq listed-in-part 1)
- (if (characterp char-range)
- (progn (unless (ucs-normalize-tests--rule2-holds-p char-range)
- (push char-range failed-chars))
- (progress-reporter-update reporter char-range))
- (cl-loop for char from (car char-range) to (cdr char-range)
- unless (ucs-normalize-tests--rule2-holds-p char)
- do (push char failed-chars)
- do (progress-reporter-update reporter char)))))
- chars-part1)
+ 0 (max-char t)))
+ (failed-chars nil)
+ (unicode-max (max-char t)))
+ (with-current-buffer ucs-normalize-tests--norm-buf
+ (map-char-table
+ (lambda (char-range listed-in-part)
+ (unless (eq listed-in-part 1)
+ (if (characterp char-range)
+ (progn (unless (ucs-normalize-tests--rule2-holds-p char-range)
+ (push char-range failed-chars))
+ (progress-reporter-update reporter char-range))
+ (cl-loop for char from (car char-range) to (min (cdr char-range)
+ unicode-max)
+ unless (ucs-normalize-tests--rule2-holds-p char)
+ do (push char failed-chars)
+ do (progress-reporter-update reporter char)))))
+ chars-part1))
(progress-reporter-done reporter)
failed-chars))
(ert-deftest ucs-normalize-part1 ()
:tags '(:expensive-test)
- (skip-unless (not (getenv "EMACS_HYDRA_CI"))) ; SLOW ~ 1800s
+ (skip-unless (not (or (getenv "EMACS_HYDRA_CI")
+ (getenv "EMACS_EMBA_CI")))) ; SLOW ~ 1800s
;; This takes a long time, so make sure we're compiled.
(dolist (fun '(ucs-normalize-tests--part1-rule2
ucs-normalize-tests--rule1-failing-for-partX
diff --git a/test/lisp/net/tramp-archive-tests.el b/test/lisp/net/tramp-archive-tests.el
index f8a0aa03e32..d9eafc47ad7 100644
--- a/test/lisp/net/tramp-archive-tests.el
+++ b/test/lisp/net/tramp-archive-tests.el
@@ -123,7 +123,7 @@ the origin of the temporary TMPFILE, have no write permissions."
(defun tramp-archive--test-emacs27-p ()
"Check for Emacs version >= 27.1.
-Some semantics has been changed for there, w/o new functions or
+Some semantics has been changed for there, without new functions or
variables, so we check the Emacs version directly."
(>= emacs-major-version 27))
diff --git a/test/lisp/net/tramp-tests.el b/test/lisp/net/tramp-tests.el
index 6ffb8a65292..79b2fc803d6 100644
--- a/test/lisp/net/tramp-tests.el
+++ b/test/lisp/net/tramp-tests.el
@@ -6597,20 +6597,20 @@ INPUT, if non-nil, is a string sent to the process."
(defun tramp--test-emacs27-p ()
"Check for Emacs version >= 27.1.
-Some semantics has been changed for there, w/o new functions or
-variables, so we check the Emacs version directly."
+Some semantics has been changed for there, without new functions
+or variables, so we check the Emacs version directly."
(>= emacs-major-version 27))
(defun tramp--test-emacs28-p ()
"Check for Emacs version >= 28.1.
-Some semantics has been changed for there, w/o new functions or
-variables, so we check the Emacs version directly."
+Some semantics has been changed for there, without new functions
+or variables, so we check the Emacs version directly."
(>= emacs-major-version 28))
(defun tramp--test-emacs29-p ()
"Check for Emacs version >= 29.1.
-Some semantics has been changed for there, w/o new functions or
-variables, so we check the Emacs version directly."
+Some semantics has been changed for there, without new functions
+or variables, so we check the Emacs version directly."
(>= emacs-major-version 29))
(defun tramp--test-adb-p ()
diff --git a/test/lisp/progmodes/project-tests.el b/test/lisp/progmodes/project-tests.el
index d4b6bca7e8f..c3b886873d3 100644
--- a/test/lisp/progmodes/project-tests.el
+++ b/test/lisp/progmodes/project-tests.el
@@ -110,4 +110,33 @@ When `project-ignores' includes a name matching project dir."
(list
(expand-file-name "some-file" dir)))))))
+(defvar project-tests--this-file (or (bound-and-true-p byte-compile-current-file)
+ (and load-in-progress load-file-name)
+ buffer-file-name))
+
+(ert-deftest project-vc-recognizes-git ()
+ "Check that Git repository is detected."
+ (skip-unless (eq (vc-responsible-backend default-directory) 'Git))
+ (let* ((vc-handled-backends '(Git))
+ (dir (file-name-directory project-tests--this-file))
+ (_ (vc-file-clearprops dir))
+ (project-vc-extra-root-markers nil)
+ (project (project-current nil dir)))
+ (should-not (null project))
+ (should (string-match-p
+ "\\`test/lisp/progmodes/project-tests\\.elc?"
+ (file-relative-name
+ project-tests--this-file
+ (project-root project))))))
+
+(ert-deftest project-vc-extra-root-markers-supports-wildcards ()
+ "Check that one can add wildcard entries."
+ (skip-unless (eq (vc-responsible-backend default-directory) 'Git))
+ (let* ((dir (file-name-directory project-tests--this-file))
+ (_ (vc-file-clearprops dir))
+ (project-vc-extra-root-markers '("files-x-tests.*"))
+ (project (project-current nil dir)))
+ (should-not (null project))
+ (should (string-match-p "/test/lisp/\\'" (project-root project)))))
+
;;; project-tests.el ends here
diff --git a/test/lisp/progmodes/python-tests.el b/test/lisp/progmodes/python-tests.el
index f871b7bc7d9..17d6d8aa706 100644
--- a/test/lisp/progmodes/python-tests.el
+++ b/test/lisp/progmodes/python-tests.el
@@ -280,28 +280,33 @@ aliqua."
"a, b, c = 1, 2, 3"
'((1 . font-lock-variable-name-face) (2)
(4 . font-lock-variable-name-face) (5)
- (7 . font-lock-variable-name-face) (8))))
+ (7 . font-lock-variable-name-face) (8)
+ (9 . font-lock-operator-face) (10))))
(ert-deftest python-font-lock-assignment-statement-2 ()
(python-tests-assert-faces
"a, *b, c = 1, 2, 3, 4, 5"
'((1 . font-lock-variable-name-face) (2)
+ (4 . font-lock-operator-face)
(5 . font-lock-variable-name-face) (6)
- (8 . font-lock-variable-name-face) (9))))
+ (8 . font-lock-variable-name-face) (9)
+ (10 . font-lock-operator-face) (11))))
(ert-deftest python-font-lock-assignment-statement-3 ()
(python-tests-assert-faces
"[a, b] = (1, 2)"
'((1)
(2 . font-lock-variable-name-face) (3)
- (5 . font-lock-variable-name-face) (6))))
+ (5 . font-lock-variable-name-face) (6)
+ (8 . font-lock-operator-face) (9))))
(ert-deftest python-font-lock-assignment-statement-4 ()
(python-tests-assert-faces
"(l[1], l[2]) = (10, 11)"
'((1)
(2 . font-lock-variable-name-face) (3)
- (8 . font-lock-variable-name-face) (9))))
+ (8 . font-lock-variable-name-face) (9)
+ (14 . font-lock-operator-face) (15))))
(ert-deftest python-font-lock-assignment-statement-5 ()
(python-tests-assert-faces
@@ -310,22 +315,29 @@ aliqua."
(2 . font-lock-variable-name-face) (3)
(5 . font-lock-variable-name-face) (6)
(8 . font-lock-variable-name-face) (9)
+ (11 . font-lock-operator-face)
(12 . font-lock-variable-name-face) (13)
+ (15 . font-lock-operator-face) (16)
+ (17 . font-lock-operator-face)
(18 . font-lock-variable-name-face) (19)
- (21 . font-lock-variable-name-face) (22))))
+ (21 . font-lock-variable-name-face) (22)
+ (23 . font-lock-operator-face) (24))))
(ert-deftest python-font-lock-assignment-statement-6 ()
(python-tests-assert-faces
"(a,) = 'foo',"
'((1)
(2 . font-lock-variable-name-face) (3)
+ (6 . font-lock-operator-face) (7)
(8 . font-lock-string-face) (13))))
(ert-deftest python-font-lock-assignment-statement-7 ()
(python-tests-assert-faces
"(*a,) = ['foo', 'bar', 'baz']"
'((1)
+ (2 . font-lock-operator-face)
(3 . font-lock-variable-name-face) (4)
+ (7 . font-lock-operator-face) (8)
(10 . font-lock-string-face) (15)
(17 . font-lock-string-face) (22)
(24 . font-lock-string-face) (29))))
@@ -334,6 +346,7 @@ aliqua."
(python-tests-assert-faces
"d = D('a', ['b'], 'c')"
'((1 . font-lock-variable-name-face) (2)
+ (3 . font-lock-operator-face) (4)
(7 . font-lock-string-face) (10)
(13 . font-lock-string-face) (16)
(19 . font-lock-string-face) (22))))
@@ -344,7 +357,9 @@ aliqua."
'((1)
(3 . font-lock-variable-name-face) (4)
(8 . font-lock-variable-name-face) (9)
+ (14 . font-lock-operator-face) (15)
(17 . font-lock-variable-name-face) (18)
+ (19 . font-lock-operator-face) (20)
(21 . font-lock-string-face) (24)
(26 . font-lock-string-face) (29)
(31 . font-lock-string-face) (34)
@@ -355,7 +370,8 @@ aliqua."
(python-tests-assert-faces
"a: int = 5"
'((1 . font-lock-variable-name-face) (2)
- (4 . font-lock-builtin-face) (7))))
+ (4 . font-lock-builtin-face) (7)
+ (8 . font-lock-operator-face) (9))))
(ert-deftest python-font-lock-assignment-statement-11 ()
(python-tests-assert-faces
@@ -364,13 +380,15 @@ aliqua."
(19 . font-lock-builtin-face) (22)
(40 . font-lock-builtin-face) (43)
(46 . font-lock-builtin-face) (49)
+ (52 . font-lock-operator-face) (53)
(55 . font-lock-constant-face) (59)
(61 . font-lock-string-face) (66))))
(ert-deftest python-font-lock-assignment-statement-12 ()
(python-tests-assert-faces
"c: Collection = {1, 2, 3}"
- '((1 . font-lock-variable-name-face) (2))))
+ '((1 . font-lock-variable-name-face) (2)
+ (15 . font-lock-operator-face) (16))))
(ert-deftest python-font-lock-assignment-statement-13 ()
(python-tests-assert-faces
@@ -378,6 +396,7 @@ aliqua."
'((1 . font-lock-variable-name-face) (2)
(12 . font-lock-builtin-face) (15)
(17 . font-lock-builtin-face) (20)
+ (22 . font-lock-operator-face) (23)
(28 . font-lock-string-face) (33)
(38 . font-lock-string-face) (43))))
@@ -386,28 +405,38 @@ aliqua."
"(a) = 5; (b) = 6"
'((1)
(2 . font-lock-variable-name-face) (3)
- (11 . font-lock-variable-name-face) (12))))
+ (5 . font-lock-operator-face) (6)
+ (11 . font-lock-variable-name-face) (12)
+ (14 . font-lock-operator-face) (15))))
(ert-deftest python-font-lock-assignment-statement-15 ()
(python-tests-assert-faces
"[a] = 5,; [b] = 6,"
'((1)
(2 . font-lock-variable-name-face) (3)
- (12 . font-lock-variable-name-face) (13))))
+ (5 . font-lock-operator-face) (6)
+ (12 . font-lock-variable-name-face) (13)
+ (15 . font-lock-operator-face) (16))))
(ert-deftest python-font-lock-assignment-statement-16 ()
(python-tests-assert-faces
"[*a] = 5, 6; [*b] = 7, 8"
'((1)
+ (2 . font-lock-operator-face)
(3 . font-lock-variable-name-face) (4)
- (16 . font-lock-variable-name-face) (17))))
+ (6 . font-lock-operator-face) (7)
+ (15 . font-lock-operator-face)
+ (16 . font-lock-variable-name-face) (17)
+ (19 . font-lock-operator-face) (20))))
(ert-deftest python-font-lock-assignment-statement-17 ()
(python-tests-assert-faces
"(a) = (b) = 1"
- `((1)
+ '((1)
(2 . font-lock-variable-name-face) (3)
- (8 . font-lock-variable-name-face) (9))))
+ (5 . font-lock-operator-face) (6)
+ (8 . font-lock-variable-name-face) (9)
+ (11 . font-lock-operator-face) (12))))
(ert-deftest python-font-lock-assignment-statement-18 ()
(python-tests-assert-faces
@@ -420,13 +449,21 @@ def f(x: CustomInt) -> CustomInt:
return res
"
'((1 . font-lock-variable-name-face) (10)
+ (11 . font-lock-operator-face) (12)
(13 . font-lock-builtin-face) (16)
(18 . font-lock-keyword-face) (21)
(22 . font-lock-function-name-face) (23)
+ (38 . font-lock-operator-face) (40)
(56 . font-lock-variable-name-face) (57)
+ (58 . font-lock-operator-face) (59)
+ (62 . font-lock-operator-face) (63)
(70 . font-lock-variable-name-face) (72)
+ (94 . font-lock-operator-face) (95)
+ (102 . font-lock-operator-face) (103)
(111 . font-lock-variable-name-face) (114)
+ (126 . font-lock-operator-face) (127)
(128 . font-lock-builtin-face) (131)
+ (136 . font-lock-operator-face) (137)
(144 . font-lock-keyword-face) (150))))
(ert-deftest python-font-lock-assignment-statement-multiline-1 ()
@@ -442,7 +479,8 @@ def f(x: CustomInt) -> CustomInt:
"
'((1)
(8 . font-lock-variable-name-face) (9)
- (15 . font-lock-variable-name-face) (16))
+ (15 . font-lock-variable-name-face) (16)
+ (19 . font-lock-operator-face) (20))
"#" "="))
(ert-deftest python-font-lock-assignment-statement-multiline-2 ()
@@ -453,7 +491,9 @@ def f(x: CustomInt) -> CustomInt:
] # 5, 6
"
'((1)
- (9 . font-lock-variable-name-face) (10))
+ (8 . font-lock-operator-face)
+ (9 . font-lock-variable-name-face) (10)
+ (13 . font-lock-operator-face) (14))
"#" "="))
(ert-deftest python-font-lock-assignment-statement-multiline-3 ()
@@ -471,7 +511,8 @@ def f(x: CustomInt) -> CustomInt:
3"
'((1 . font-lock-variable-name-face) (2)
(15 . font-lock-variable-name-face) (16)
- (29 . font-lock-variable-name-face) (30))
+ (29 . font-lock-variable-name-face) (30)
+ (36 . font-lock-operator-face) (37))
"#" "="))
(ert-deftest python-font-lock-assignment-statement-multiline-4 ()
@@ -482,7 +523,8 @@ def f(x: CustomInt) -> CustomInt:
#\\
5"
'((1 . font-lock-variable-name-face) (2)
- (15 . font-lock-builtin-face) (18))
+ (15 . font-lock-builtin-face) (18)
+ (24 . font-lock-operator-face) (25))
"#" "="))
(ert-deftest python-font-lock-assignment-statement-multiline-5 ()
@@ -500,7 +542,9 @@ def f(x: CustomInt) -> CustomInt:
6"
'((1)
(8 . font-lock-variable-name-face) (9)
- (46 . font-lock-variable-name-face) (47))
+ (18 . font-lock-operator-face) (19)
+ (46 . font-lock-variable-name-face) (47)
+ (60 . font-lock-operator-face) (61))
"#" "="))
(ert-deftest python-font-lock-assignment-statement-multiline-6 ()
@@ -518,9 +562,33 @@ def f(x: CustomInt) -> CustomInt:
6"
'((1)
(7 . font-lock-variable-name-face) (8)
- (43 . font-lock-variable-name-face) (44))
+ (16 . font-lock-operator-face) (17)
+ (43 . font-lock-variable-name-face) (44)
+ (56 . font-lock-operator-face) (57))
"#" "="))
+(ert-deftest python-font-lock-operator-1 ()
+ (python-tests-assert-faces
+ "1 << 2 ** 3 == +4%-5|~6&7^8%9"
+ '((1)
+ (3 . font-lock-operator-face) (5)
+ (8 . font-lock-operator-face) (10)
+ (13 . font-lock-operator-face) (15)
+ (16 . font-lock-operator-face) (17)
+ (18 . font-lock-operator-face) (20)
+ (21 . font-lock-operator-face) (23)
+ (24 . font-lock-operator-face) (25)
+ (26 . font-lock-operator-face) (27)
+ (28 . font-lock-operator-face) (29))))
+
+(ert-deftest python-font-lock-operator-2 ()
+ "Keyword operators are font-locked as keywords."
+ (python-tests-assert-faces
+ "is_ is None"
+ '((1)
+ (5 . font-lock-keyword-face) (7)
+ (8 . font-lock-constant-face))))
+
(ert-deftest python-font-lock-escape-sequence-string-newline ()
(python-tests-assert-faces
"'\\n'
@@ -603,12 +671,16 @@ u\"\\n\""
(196 . font-lock-constant-face)
(215 . font-lock-string-face) (218)
(221 . font-lock-string-face) (254)
+ (259 . font-lock-operator-face) (260)
(271 . font-lock-string-face) (274)
(277 . font-lock-string-face) (310)
+ (315 . font-lock-operator-face) (316)
(327 . font-lock-string-face) (330)
(333 . font-lock-string-face) (366)
+ (371 . font-lock-operator-face) (372)
(383 . font-lock-string-face) (386)
(389 . font-lock-string-face) (422)
+ (427 . font-lock-operator-face) (428)
(439 . font-lock-string-face) (442)
(444 . font-lock-string-face) (497)
(499 . font-lock-string-face) (552)
@@ -4566,6 +4638,11 @@ import abc
(ert-deftest python-ffap-module-path-1 ()
(skip-unless (executable-find python-tests-shell-interpreter))
+ ;; Skip the test on macOS, since the standard Python installation uses
+ ;; libedit rather than readline which confuses the running of an inferior
+ ;; interpreter in this case (see bug#59477 and bug#25753).
+ (skip-unless (not (eq system-type 'darwin)))
+ (trace-function 'python-shell-output-filter)
(python-tests-with-temp-buffer-with-shell
"
import abc
diff --git a/test/lisp/server-tests.el b/test/lisp/server-tests.el
index f8ecd046f2b..ebf84481c61 100644
--- a/test/lisp/server-tests.el
+++ b/test/lisp/server-tests.el
@@ -21,9 +21,11 @@
(require 'ert)
(require 'server)
+(require 'cl-lib)
(defconst server-tests/can-create-frames-p
- (not (memq system-type '(windows-nt ms-dos)))
+ (and (not (memq system-type '(windows-nt ms-dos)))
+ (not (member (getenv "TERM") '("dumb" "" nil))))
"Non-nil if we can create a new frame in the tests.
Some tests below need to create new frames for the emacsclient.
However, this doesn't work on all platforms. In particular,
@@ -188,8 +190,9 @@ tests that `server-force-stop' doesn't delete frames (and even
then, requires a few tricks to run as a regression test). So
long as this works, the problem in bug#58877 shouldn't occur."
(skip-unless server-tests/can-create-frames-p)
- (let ((starting-frame-count (length (frame-list)))
- terminal)
+ (let* ((starting-frames (frame-list))
+ (starting-frame-count (length starting-frames))
+ terminal)
(unwind-protect
(server-tests/with-server
(server-tests/with-client emacsclient '("-c") 'exit
@@ -214,6 +217,9 @@ long as this works, the problem in bug#58877 shouldn't occur."
(when (and terminal
(eq (terminal-live-p terminal) t)
(not (eq system-type 'windows-nt)))
- (delete-terminal terminal)))))
+ (delete-terminal terminal)))
+ ;; Delete the created frame.
+ (delete-frame (car (cl-set-difference (frame-list) starting-frames))
+ t)))
;;; server-tests.el ends here
diff --git a/test/manual/cedet/cedet-utests.el b/test/manual/cedet/cedet-utests.el
index b365908c639..2c5ba46855d 100644
--- a/test/manual/cedet/cedet-utests.el
+++ b/test/manual/cedet/cedet-utests.el
@@ -333,7 +333,8 @@ ERRORCONDITION is some error that may have occurred during testing."
"Add into the log that the last item is done.
Apply NOTES to the doneness of the log.
Apply ERR if there was an error in previous item.
-Optional argument PRECR indicates to prefix the done msg w/ a newline."
+Optional argument PRECR indicates to prefix the done message with
+a newline."
(if noninteractive
;; Non-interactive-mode - show a message.
(if notes
diff --git a/test/manual/cedet/semantic-tests.el b/test/manual/cedet/semantic-tests.el
index dcdeb45b0a3..1d0e668d96f 100644
--- a/test/manual/cedet/semantic-tests.el
+++ b/test/manual/cedet/semantic-tests.el
@@ -87,7 +87,8 @@ run the test again")))
(defun semanticdb-test-gnu-global (searchfor &optional standardfile)
"Test the GNU Global semanticdb.
Argument SEARCHFOR is the text to search for.
-If optional arg STANDARDFILE is non-nil, use a standard file w/ global enabled."
+If optional arg STANDARDFILE is non-nil, use a standard file with
+global enabled."
(interactive "sSearch For Tag: \nP")
(require 'data-debug)
diff --git a/test/manual/cedet/tests/testpolymorph.cpp b/test/manual/cedet/tests/testpolymorph.cpp
index ba64e39a7a5..cfe44ecc4d3 100644
--- a/test/manual/cedet/tests/testpolymorph.cpp
+++ b/test/manual/cedet/tests/testpolymorph.cpp
@@ -22,7 +22,7 @@
#include <cmath>
-// Test 1 - Functions w/ prototypes
+// Test 1 - Functions with prototypes
namespace proto {
int pt_func1(int arg1);
@@ -32,7 +32,7 @@ namespace proto {
}
-// Test 2 - Functions w/ different arg lists.
+// Test 2 - Functions with different arg lists.
namespace fcn_poly {
int pm_func(void) {
@@ -50,7 +50,7 @@ namespace fcn_poly {
}
-// Test 3 - Methods w/ different arg lists.
+// Test 3 - Methods with different arg lists.
class meth_poly {
public:
int pm_meth(void) {
@@ -68,7 +68,7 @@ public:
};
-// Test 4 - Templates w/ partial specifiers.
+// Test 4 - Templates with partial specifiers.
namespace template_partial_spec {
template <typename T> class test
{
@@ -83,7 +83,7 @@ namespace template_partial_spec {
};
}
-// Test 5 - Templates w/ full specialization which may or may not share
+// Test 5 - Templates with full specialization which may or may not share
// common functions.
namespace template_full_spec {
template <typename T> class test
diff --git a/test/manual/cedet/tests/testsppreplace.c b/test/manual/cedet/tests/testsppreplace.c
index 54ae3f0323e..d255c202d35 100644
--- a/test/manual/cedet/tests/testsppreplace.c
+++ b/test/manual/cedet/tests/testsppreplace.c
@@ -66,7 +66,7 @@ int myFcn3 (int a, int b);
MULTI_ARGS(ma_struct, moose, penguin, emu);
-/* TEST: Macro w/ args, but no body. */
+/* TEST: Macro with args, but no body. */
#define NO_BODY(name)
NO_BODY(Moose);
@@ -78,7 +78,7 @@ int not_with_args_fcn NOT_WITH_ARGS
{
}
-/* TEST: macro w/ continuation. */
+/* TEST: macro with continuation. */
#define WITH_CONT \
continuation_symbol
diff --git a/test/manual/cedet/tests/testsppreplaced.c b/test/manual/cedet/tests/testsppreplaced.c
index c359fa7d690..c98349174e5 100644
--- a/test/manual/cedet/tests/testsppreplaced.c
+++ b/test/manual/cedet/tests/testsppreplaced.c
@@ -55,14 +55,14 @@ int myFcn3 (int a, int b);
/* TEST: Multiple args to a macro. */
struct ma_struct { int moose; int penguin; int emu; };
-/* TEST: Macro w/ args, but no body. */
+/* TEST: Macro with args, but no body. */
/* TEST: Not a macro with args, but close. */
int not_with_args_fcn (moose)
{
}
-/* TEST: macro w/ continuation. */
+/* TEST: macro with continuation. */
int continuation_symbol () { };
/* TEST: macros in a macro - tail processing */
diff --git a/test/src/sqlite-tests.el b/test/src/sqlite-tests.el
index e9ddf9c0bef..a2472c43dad 100644
--- a/test/src/sqlite-tests.el
+++ b/test/src/sqlite-tests.el
@@ -36,6 +36,7 @@
(declare-function sqlite-select "sqlite.c")
(declare-function sqlite-open "sqlite.c")
(declare-function sqlite-load-extension "sqlite.c")
+(declare-function sqlite-version "sqlite.c")
(ert-deftest sqlite-select ()
(skip-unless (sqlite-available-p))
diff --git a/test/src/treesit-tests.el b/test/src/treesit-tests.el
index 80fde408cd3..aba12759c34 100644
--- a/test/src/treesit-tests.el
+++ b/test/src/treesit-tests.el
@@ -143,6 +143,8 @@
(treesit-node-string
(treesit-node-first-child-for-pos
doc-node 3))))
+ (should-error (treesit-node-first-child-for-pos doc-node 100)
+ :type 'args-out-of-range)
;; `treesit-node-descendant-for-range'.
(should (equal "(\"{\")"
(treesit-node-string
@@ -152,6 +154,9 @@
(treesit-node-string
(treesit-node-descendant-for-range
root-node 6 7 t))))
+ (should-error (treesit-node-descendant-for-range
+ root-node 100 101)
+ :type 'args-out-of-range)
;; `treesit-node-eq'.
(should (treesit-node-eq root-node root-node))
(should (not (treesit-node-eq root-node doc-node))))))
@@ -167,6 +172,9 @@
(setq root-node (treesit-parser-root-node
parser)))
+ (should-error (treesit-query-capture root-node "" 100 101)
+ :type 'args-out-of-range)
+
;; Test `treesit-query-capture' on string, sexp and compiled
;; queries.
(dolist (query1