Commit graph

8675 commits

Author SHA1 Message Date
Michael Albinus
fe45d875a4 ; Fix last Tramp change 2026-06-11 14:52:55 +02:00
Michael Albinus
f89ff62367 Extend Tramp external operations
* doc/misc/tramp.texi (New operations): Extend.

* lisp/net/tramp.el (tramp-file-name-for-operation-external):
Extend docstring.
(tramp-file-name-for-operation): Make more use of
`tramp-file-name-for-operation-external'.
(tramp-add-external-operation): Support ARG-TYPE `tramp-file-name'.

* test/lisp/net/tramp-tests.el (tramp-test49-external-backend-function):
Extend test.
2026-06-10 15:45:31 +02:00
Sean Whitton
cd84bd6a0c vc-dir-recompute-file-state: Change directory to DEF-DIR
* lisp/vc/vc-dir.el (vc-dir-recompute-file-state): Change
directory to DEF-DIR before calling into the backend.
* test/lisp/vc/vc-tests/vc-test-misc.el
(vc-test-vc-dir-on-symlink): Test that the file has the right
state.
2026-06-10 13:36:52 +01:00
Eli Zaretskii
a21614d4d6 ; Skip one vc-dir test on MS-Windows
* test/lisp/vc/vc-tests/vc-test-misc.el
(vc-test-vc-dir-on-symlink): Skip in MS-Windows.
2026-06-09 16:50:48 +03:00
Sean Whitton
71ea4bbb6c vc-test-vc-dir-on-symlink: Use vc-test--with-author-identity
* test/lisp/vc/vc-tests/vc-tests.el (vc-hg-global-switches):
Declare.
(vc-tests-helpers): Require.
(vc-test--create-repo-function, vc-test--with-author-identity):
Move these from here ...
* test/lisp/vc/vc-tests/resources/vc-tests-helpers.el
(vc-test--create-repo-function, vc-test--with-author-identity):
... to here.
(vc-hg-global-switches):
* test/lisp/vc/vc-tests/vc-test-misc.el (vc-hg-global-switches):
Declare.
(vc-dir, log-edit, vc-tests-helpers): Require.
(vc-test-vc-dir-on-symlink): Use vc-test--with-author-identity
and vc-test--create-repo-function.
2026-06-09 11:21:33 +01:00
Sean Whitton
c244314974 Fix recurrence of bug#80803 after changes in bug#80967
* lisp/vc/vc-dir.el (vc-dir-resynch-file): Pass only truenames
to vc-dir-recompute-file-state.
* test/lisp/vc/vc-tests/vc-test-misc.el (vc-git): Require.
(vc-test-vc-dir-on-symlink): New test.
2026-06-08 15:29:12 +01:00
Juri Linkov
9e37c94079 Read a key sequence instead of a single key in 'map-y-or-n-p'
This is necessary to correctly read keys like 'M-~'
used by 'save-some-buffers' that is two keys 'ESC ~'
on a tty.

* doc/lispref/minibuf.texi (Multiple Queries):
Index 'y-or-n-p-use-read-key' for 'map-y-or-n-p'.
Mention using a key sequence instead of single keys.

* lisp/emacs-lisp/map-ynp.el (map-y-or-n-p):
In the 'y-or-n-p-use-read-key' cond-branch,
use 'read-key-sequence-vector' instead of 'read-key'.
In the default cond-branch, use 'this-command-keys-vector'
instead of 'last-command-event'.  In both cond-branches
use 'key-description' instead of 'single-key-description'
(bug#81168).
Instead of '(eq def nil)' check if chars are either nil
or an empty vector in noninteractive mode (bug#67836).

* test/lisp/emacs-lisp/map-ynp-tests.el (test-map-ynp-kmacro):
Test separately nil/non-nil 'y-or-n-p-use-read-key'.
(test-map-ynp-keys): New test for complete coverage of
'map-y-or-n-p'.
2026-06-07 21:56:47 +03:00
Sean Whitton
fd1b5cd890 ; * test/lisp/files-tests.el (w32-downcase-file-names): Declare. 2026-06-05 13:07:24 +01:00
Michael Albinus
fe1c02d849 Fix Tramp distrobox integration
* lisp/net/tramp.el (tramp-yesno-prompt-regexp): Fix docstring.
(tramp-yn-prompt-regexp): Fix docstring.  Extend.  Add :version.

* test/lisp/net/tramp-tests.el (tramp-test03-file-error): Adapt test.
2026-06-04 08:34:48 +02:00
F. Jason Park
05f89d711d Fix more missing faces on ERC margin strings
* lisp/erc/erc-goodies.el (keep-place-indicator): Add
`erc-keep-place-indicator-arrow' face to overlay arrow.
* lisp/erc/erc-stamp.el (erc-stamp--display-prompt-in-left-margin)
(erc--conceal-prompt): Add `erc-prompt-face' to entire `left-margin'
string.  See also 9ba65aa9 "Fix missing margin face on display prop in
erc-stamp".
* test/lisp/erc/erc-fill-tests.el (erc-fill--left-hand-stamps): Update
expected text properties on prompt.  (Bug#80693)
2026-06-01 23:09:55 -07:00
Juri Linkov
271cc5c76c More tests for fill-paragraph-handle-comment.erts
* test/lisp/textmodes/fill-resources/fill-paragraph-handle-comment.erts:
Add more tests for current comment lines (bug#80449).
2026-05-31 21:36:12 +03:00
Juri Linkov
2e70b88623 Fix fill-paragraph combining text with preceding comment
* lisp/textmodes/fill.el (fill-paragraph): Handle the case
when a non-comment line follows a comment line with
non-nil 'fill-paragraph-handle-comment' (bug#80449).
Skip such a comment line before filling a non-comment line.

* test/lisp/textmodes/fill-tests.el
(fill-test-fill-paragraph-handle-comment): Add new test.

* test/lisp/textmodes/fill-resources/fill-paragraph-handle-comment.erts:
New file.
2026-05-27 18:32:40 +03:00
Michael Albinus
c618178066 ; Mark process-test-stderr-buffer as :unstable when running on emba
* test/src/process-tests.el (process-test-stderr-buffer): Mark as
:unstable when running on emba.  (Bug#80166)
2026-05-25 08:44:42 +02:00
Sean Whitton
dd42133315 vc-test--rename-file: Disable part of test for SCCS
* test/lisp/vc/vc-tests/vc-tests.el (vc-test--rename-file):
Disable part of test for SCCS.
2026-05-23 16:53:36 +01:00
Richard Lawrence
70b79b3ed8 Rename `icalendar-recur' type and related functions
More context in Bug#80786 and:
https://lists.gnu.org/archive/html/emacs-orgmode/2026-03/msg00286.html

`icalendar-recur' as a type name for RRULE values was confusing and made
the accessors for this type difficult to discover, because `icalendar-recur-'
is also used as a prefix in icalendar-recur.el.  This change renames the
`icalendar-recur' type to `icalendar-rrule-value' and renames the
accessor functions for these values appropriately.

* lisp/calendar/icalendar-parser.el:  Rename symbols as follows:
(icalendar-recur): `icalendar-rrule-value'
(icalendar-read-recur-rule-part): `icalendar-read-rrule-part'
(icalendar-print-recur-rule-part): `icalendar-print-rrule-part'
(icalendar-recur-rule-part): `icalendar-rrule-part'
(icalendar-read-recur): `icalendar-read-rrule-value'
(icalendar-print-recur): `icalendar-print-rrule-value'
(icalendar--recur-value-types): `icalendar--rrule-value-types'
(icalendar-recur-value-p): `icalendar-rrule-value-p'
(icalendar-recur-freq): `icalendar-rrule-freq'
(icalendar-recur-interval-size): `icalendar-rrule-interval-size'
(icalendar-recur-until): `icalendar-rrule-until'
(icalendar-recur-count): `icalendar-rrule-count'
(icalendar-recur-weekstart): `icalendar-rrule-weekstart'
(icalendar-recur-by*): `icalendar-rrule-by*'.
(icalendar-rrule):
(icalendar-index-insert):
(icalendar-index-get): Update references.
* lisp/calendar/icalendar-recur.el (icalendar-recur-find-interval):
(icalendar-recur-nth-interval):
(icalendar-recur-next-interval):
(icalendar-recur-previous-interval):
(icalendar-recur-refine-from-clauses):
(icalendar-recur-recurrences-in-interval):
(icalendar-recur-recurrences-in-window):
(icalendar-recur-recurrences-to-count):
(icalendar-recur-tz-observance-on): Update references.
* lisp/calendar/diary-icalendar.el: Update references.
* lisp/calendar/icalendar-shortdoc.el (icalendar): Update shortdoc examples.
* lisp/gnus/gnus-icalendar.el: Update references.
* test/lisp/calendar/diary-icalendar-tests.el:
* test/lisp/calendar/icalendar-parser-tests.el:
* test/lisp/calendar/icalendar-recur-tests.el: Update references in tests.
2026-05-23 13:25:19 +03:00
Michael Albinus
3d2bb233f2 ; Minor Tramp changes
* doc/misc/tramp.texi (Frequently Asked Questions):
google-drive has been disabled in GNOME 50.

* lisp/net/tramp-cmds.el (tramp-enable-method): Upcase prompt.

* lisp/net/tramp-sh.el (tramp-sh-handle-make-process)
(tramp-sh-handle-process-file): Improve setting of environment variables.

* test/lisp/net/tramp-tests.el (tramp-methods) <mock>:
Add `tramp-tmpdir'.  Adapt `tramp-login-program'.
(ert-remote-temporary-file-directory): Improve expansion.
(tramp-test35-remote-path): Adapt test.
2026-05-23 10:25:46 +02:00
F. Jason Park
9ba65aa965 Fix missing margin face on display prop in erc-stamp
* lisp/erc/erc-stamp.el (erc-insert-timestamp-right): Explicitly add
face to right-hand stamp's `display' margin string.  Commit d24b10ca
"Introduce 'margin' face for window margin background" did away with the
"fall-through" behavior in which a margin spec's string that lacks its
own face property inherited whatever the associated `display' char
happened to have.  (Bug#80693)

;; The old language in "(elisp) Display Margins" said "if the
;; string to be displayed in the margin doesn't specify a face, its
;; face is determined using the same rules and priorities as it is
;; for strings displayed in the text area (see Displaying Faces),"
;; and that "if this results in undesirable 'leaking' of faces into
;; the margin, make sure the string has an explicit face specified
;; for it."  It seems ERC and likely more than a few other packages
;; never came to heed this guidance and have erroneously depended
;; on such behavior for years if not decades.
;;
;; * test/lisp/erc/resources/fill/snapshots/merge-01-start.eld:
;; * test/lisp/erc/resources/fill/snapshots/merge-02-right.eld:
;; * test/lisp/erc/resources/fill/snapshots/merge-wrap-01.eld:
;; * test/lisp/erc/resources/fill/snapshots/merge-wrap-indicator-pre-01.eld:
;; * test/lisp/erc/resources/fill/snapshots/monospace-01-start.eld:
;; * test/lisp/erc/resources/fill/snapshots/monospace-02-right.eld:
;; * test/lisp/erc/resources/fill/snapshots/monospace-03-left.eld:
;; * test/lisp/erc/resources/fill/snapshots/monospace-04-reset.eld:
;; * test/lisp/erc/resources/fill/snapshots/spacing-01-mono.eld: Update
;; snapshot.
2026-05-18 15:07:34 -07:00
João Távora
6bd73af241 ; * test/lisp/jsonrpc-tests.el: Adjust timeouts for CI EMBA testing 2026-05-18 17:22:30 +01:00
João Távora
36036e71c0 Jsonrpc: migrate more tests to Python subprocess fixtures
All tests now use 'jsonrpc--with-python-fixture' with a Python3
subprocess instead of the in-Emacs TCP server.  Changed the "harakiri"
method to be a request instead of a notification for to reduce chance of
"Sentinel hasn't run" warning.

The two in-Emacs-RPC-specific error tests ('errors-with--32601' and
'signals-an--32603-JSONRPC-error') are dropped with the fixture itself,
as the error paths they exercise are internal to the Emacs Lisp
dispatcher and have no direct Python equivalent.  They will have to be
re-done later on in other form.

* test/lisp/jsonrpc-resources/server-emacsrpc.py: New file.

* test/lisp/jsonrpc-resources/server-anxious-nested.py: Use new
  harakiri.

* test/lisp/jsonrpc-resources/server-emacsrpc.py: Use new harakiri.

* test/lisp/jsonrpc-resources/server-harakiri.py: Use new harakiri.

* test/lisp/jsonrpc-resources/server-remote-during-sync-1.py: Use new
  harakiri.

* test/lisp/jsonrpc-resources/server-remote-during-sync-2.py: Use new
  harakiri.

* test/lisp/jsonrpc-resources/server-remote-error.py: Use new harakiri.

* test/lisp/jsonrpc-resources/common.py (harakiri): New definition.

* test/lisp/jsonrpc-tests.el
(jsonrpc--with-python-fixture): Rework, move up.
(jsonrpc-connection-ready-p): Move up.
(jsonrpc--call-with-emacsrpc-fixture)
(jsonrpc--with-emacsrpc-fixture)
(errors-with--32601)
(signals-an--32603-JSONRPC-error): Remove.
(returns-3, times-out, doesnt-time-out, stretching-it-but-works)
(deferred-action-toolate, deferred-action-intime)
(deferred-action-complex-tests): Migrate to Python fixture.
(scontrol-remote-during-sync-1, scontrol-remote-during-sync-2)
(scontrol-anxious-nested, scontrol-remote-error)
(shutdown-clean-after-notification): Tweak.
2026-05-17 19:28:07 +01:00
Michael Albinus
d0d657fa90 ; Minor Tramp cleanup
* lisp/net/tramp.el (tramp-unquote-shell-quote-argument): Do not
expand remote file names w/o a localname.

* test/lisp/net/tramp-tests.el
(tramp--test-supports-environment-variables-p): New defun.
(tramp-test33-environment-variables): Use it.
2026-05-14 12:31:04 +02:00
Michael Albinus
2e71d2c709 Propagate EMACSCLIENT_TRAMP to remote hosts with Tramp
* doc/misc/tramp.texi (Remote processes):
Explain `tramp-propagate-emacsclient-tramp'.

* lisp/net/tramp.el (tramp-remote-process-environment): Adapt docstring.
(tramp-propagate-emacsclient-tramp): New defcustom.
(tramp-handle-make-process):
* lisp/net/tramp-sh.el (tramp-sh-handle-make-process)
(tramp-sh-handle-process-file): Use it.

* test/lisp/net/tramp-tests.el (tramp-test33-environment-variables):
Adapt test.
2026-05-13 18:39:04 +02:00
Stefan Monnier
ff96db93f2 keyboard-tests.el: Try and fix the failure on EMBA
* test/src/keyboard-tests.el (keyboard-sigint-to-quit): Fix a small
race condition and avoid `sit-for` returning early.
2026-05-13 11:10:15 -04:00
Pip Cet
5323eebcff Test read-passwd behavior (bug#80838)
* test/lisp/auth-source-tests.el (auth-source-test--displayed-string):
(auth-source-test-read-passwd):
(auth-source-test-read-passwd-revealed):
(auth-source-test-read-passwd-nested): New.
2026-05-10 20:00:41 +00:00
Sean Whitton
fdab8a9185 ; Revert Eric's commits from February.
These will be resubmitted as patches for review.

Revert "Repair another test bollixed by aggressive optimization."
This reverts commit 47735e0243.

Revert "Repair ab ecal test by making a variable kexical,"
This reverts commit ca42055b0c.

Revert "Complete the test set for floatfns,c."
This reverts commit 1b0c8d6b95.

Revert "Tesrts for the portable primitives in fileio.c."
This reverts commit a339c6827c.

Revert "Tests for primitives in coding.c and charset.c."
This reverts commit 5749b2e4f4.

Revert "Tests for primitives from the character.c module."
This reverts commit b09f8df206.

Revert "Tests for the lreaf.c amd print.c primitives."
This reverts commit d7a3d442b4.

Revert "Tests for remaining functions iun eval.c."
This reverts commit cd038e5617.

Revert "Completing test coverage for dataa.c orimitives."
This reverts commit a6e19d6179.

Revert "More correctness tesrs for orinitives from fns.c."
This reverts commit 40ff4512ad.

Revert "More tests for edit functions, buffers, and markers."
This reverts commit 67e8f87562.

Revert "Added more buffer/marker/editing test coverage."
This reverts commit 3dda4b85e8.

Revert "Category/charset/coding + char-table tests."
This reverts commit 7a93a7b334.

Revert "More test coverage improvements."
This reverts commit fc7339c46d.

Revert "More test coverage improvements."
This reverts commit 95329bf445.

Revert "More test coverage improvements for ERT."
This reverts commit e42c579a54.

Revert "Crrections to tedt coverrage extensuion after bootstrap build."
This reverts commit 90af3295c7.

Revert "Improve test coverage of builtin predicates."
This reverts commit 6eb170b007.

Revert "Tests for 2 marker primitives previously not covered."
This reverts commit 6d7f0acf9c.

Revert "Tests for 7 editor primitives previously not covered."
This reverts commit bb403e70ae.
2026-05-07 15:29:53 +01:00
Michael Albinus
eae96d9fcb Handle long environment variables in Tramp oricesses
* lisp/net/tramp-sh.el (tramp-sh-handle-make-process):
Handle loooong environment variables.  (Bug#80783)

* test/lisp/net/tramp-tests.el (tramp-test33-environment-variables):
Adapt test.
2026-05-06 16:06:50 +02:00
Stefan Monnier
a952324e9b keyboard.c: Allow SIGINT to quit in batch mode, instead of exit
In terminal sessions, SIGINT is turned into a `quit` ELisp signal,
but in batch it has traditionally killed Emacs.  It can be very
useful to cause a `quit` from outside the process when running
in batch (e.g. for "batch" sessions that provide a REPL via stdin/out),
so add a new var 'kill-emacs-on-sigint' to control that behavior.
(bug#80942)

* src/keyboard.c (handle_interrupt_signal): Obey `kill_emacs_on_sigint`.
(init_keyboard): Use `deliver_interrupt_signal` for SIGINT also for
batch sessions.
(syms_of_keyboard): New variable `kill_emacs_on_sigint`.

* test/src/keyboard-tests.el (keyboard-sigint-to-quit): New test.

* doc/emacs/cmdargs.texi (Initial Options): Mention the effect of
`kill-emacs-on-sigint` in batch mode.
2026-05-04 12:49:35 -04:00
Michael Albinus
9c0a699c59 Adaot tramp-tests.el
* test/lisp/net/tramp-tests.el (ert-remote-temporary-file-directory):
Ensure that it is expanded.
2026-05-04 16:09:10 +02:00
João Távora
e24d9232e0 Jsonrpc: add new tests using Python subprocesses
Most of these tests are for the scontrol/"anxious continuation"
mechanism (bug#80623)

The new ERT tests use Python subprocesses via stdin/stdout pipe as
JSONRPC endpoints.  A shared framing library lives in
jsonrpc-resources/common.py.

* test/lisp/jsonrpc-tests.el (jsonrpc--test-dir): New constant.
(jsonrpc--with-python-fixture): New macro.
(scontrol-remote-during-sync-1)
(scontrol-remote-during-sync-2)
(scontrol-anxious-nested)
(scontrol-remote-error)
(shutdown-clean-after-notification): New tests.

* test/lisp/jsonrpc-resources/common.py: New file.

* test/lisp/jsonrpc-resources/server-remote-during-sync-1.py: New file.

* test/lisp/jsonrpc-resources/server-remote-during-sync-2.py: New file.

* test/lisp/jsonrpc-resources/server-anxious-nested.py: New file.

* test/lisp/jsonrpc-resources/server-remote-error.py: New file.

* test/lisp/jsonrpc-resources/server-harakiri.py: New file.
2026-05-04 13:32:37 +01:00
Chris Roberts
b376c405aa ; Add a test for sqlite-close
* test/src/sqlite-tests.el (sqlite-closed-db): Add test.
(Bug#80908)

Copyright-paperwork-exempt: yes
2026-05-02 14:20:42 +03:00
F. Jason Park
cf9728c4be Only perform erc-log-insert-log-on-open setup once
* etc/ERC-NEWS: Add entry for option `erc-log-insert-log-on-open'.
Mention deprecation of `erc-log-setup-logging'.
* lisp/erc/erc-log.el (erc-log-insert-log-on-open): Expand type from
boolean to choice of boolean, predicate, and new function item
`erc-log-new-target-buffer-p'.
(erc-log-mode, erc-log-enable, erc-log-disable): Replace
`erc-log-setup-logging' on `erc-connect-pre-hook' with
`erc-log--insert-log-on-open' at depth 80.  Replace calls to
`erc-log-setup-logging' with ones to `erc-log--setup'.
(erc-log-new-target-buffer-p): New function.  While the name could
perhaps do more to indicate that it's only useful when called from
`erc-open', that's the only place ERC typically sets up new target
buffers.
(erc-log-setup-logging): Deprecate and replace body with adapter that
calls `erc-log--setup' and `erc-log--insert-log-on-open'.
(erc-log--setup): New function whose body is mostly from the
"nondestructive" portion of `erc-log-setup-logging'.  Instead of moving
the `erc-saved-last-position' marker to the old value, expect it not to
have been initialized by `erc-initialize-log-marker' because
`erc-connect-pre-hook' now runs after this code, which is now
incorporated more judiciously into the module's "enable body".
(erc-log--insert-log-on-open): New function whose body is mostly from
the "destructive" portion of the previous incarnation of
`erc-log-setup-logging'.  Unlike the original, if option
`erc-log-insert-log-on-open' is a function, call it to decide whether to
insert a log file atop its buffer.  Also, don't advance the marker
`erc-last-saved-position' to the prompt area, where it can get stuck and
prevent logs from being saved when `erc-log-insert-log-on-open' is
non-nil.  Thanks to Libera user Lionyx for reporting the bug, which has
been around since at least ERC 5.4 and Emacs 28.1.
(erc-log-disable-logging): Remove `erc-save-buffer-in-logs' from
`write-file-functions' to undo its buffer-local addition in what is now
`erc--log-setup'.
* test/lisp/erc/erc-scenarios-log-options.el: New file.  (Bug#79665)
2026-04-30 15:46:42 -07:00
F. Jason Park
ba2a150740 Restore erc-last-saved-position from previous session
* lisp/erc/erc-log.el (erc-log-setup-logging): Restore
`erc-last-saved-position' from previous session.  By default, a
non-/QUIT disconnect does not write out any remaining buffer text to
logs, instead leaving it until the buffer or Emacs is killed.  But if a
successful reconnect occurs beforehand, the uncommitted portion must be
seen to somehow.  Before this change, it would be lost because the
function `erc-initialize-log-marker' remakes the marker at the prompt
instead of recovering the previous value as now done here.  Moreover,
the traditional workaround of customizing `erc-log-write-after-insert'
and `erc-log-write-after-send' to t should not be required to prevent
gaps in any decent IRC client.
* test/lisp/erc/erc-scenarios-log.el (erc-scenarios-log--reconnect): New
function.
(erc-scenarios-log--reconnect/auto, erc-scenarios-log--reconnect/manual):
New tests.
;; * test/lisp/erc/resources/join/reconnect/foonet-again.eld: Add QUIT.
2026-04-30 15:46:38 -07:00
F. Jason Park
40b6f0180b ; Tweak some ERC tests and related utilities
* test/lisp/erc/erc-scenarios-keep-place-indicator.el
(erc-scenarios-keep-place-indicator--follow): Intersperse more
`redisplay' calls to update the indicator's overlay.
* test/lisp/erc/erc-tests.el (erc-tests--assert-printed-in-subprocess):
Wrap CODE form in keyword sentinel.
(erc--find-mode, erc--essential-hook-ordering): Use modified interface.
(erc--find-group--real, erc--find-group/realistic): Rename former to
latter and run in subprocess.
(erc--update-modules/realistic): Redo to run in subprocess instead of
mocking.
* test/lisp/erc/resources/erc-d/erc-d-t.el
(erc-d-t-kill-related-buffers): Don't bother canceling
`erc-server-flood-timer', even in an actual ERC buffer, since
`erc-server-send-queue' first checks whether its BUFFER argument is
still live before sending anything to the process.  Also, don't bother
collecting buffers only to immediately kill them.
* test/lisp/erc/resources/erc-d/erc-d.el (erc-d--filter): Always clear
remainder.  Otherwise, partial emissions from the peer that aren't
terminated by a newline will confuse subsequent processing.
* test/lisp/erc/resources/erc-scenarios-common.el
(erc-scenarios-common--run-in-term): Look for a library called
`erc-tests-compat', which ERC uses in its external CI to provide
compatibility shims of definitions too obscure or unfit for inclusion in
the Compat package on ELPA.
* test/lisp/erc/resources/erc-tests-common.el
(erc-tests-common-kill-buffers): Also kill non-`erc-mode' buffers whose
names match a scheme used by ERC for work buffers.  Allow for the
EXTRA-BUFFERS argument to possibly contain killed and null buffers.
2026-04-30 15:46:29 -07:00
Paul Eggert
4fcc8a473a ; Spelling fixes. 2026-04-29 22:45:51 -07:00
Vladimir Kazanov
27a18cfd7e Add ERT coverage for read_key_sequence behaviour
* test/src/keyboard-tests.el
(keyboard-tests--rks-fake-posn)
(keyboard-tests--rks-observe)
(keyboard-tests--rks-execute)
(keyboard-tests--rks-with-function-key-bindings)
(keyboard-tests--rks-with-event-kinds)
(keyboard-tests--rks-call-with-live-window-maps): Test helpers.
(keyboard-tests-rks-prefix-then-key)
(keyboard-tests-rks-unbound-returns-sequence)
(keyboard-tests-rks-bound-sequence-ends-read)
(keyboard-tests-rks-decode-fires-without-binding)
(keyboard-tests-rks-input-decode-map)
(keyboard-tests-rks-function-key-map)
(keyboard-tests-rks-function-key-map-on-undefined)
(keyboard-tests-rks-key-translation-before-function-key)
(keyboard-tests-rks-function-key-skipped-when-bound)
(keyboard-tests-rks-input-decode-after-function-key)
(keyboard-tests-rks-key-translation-overrides-bound-sequence)
(keyboard-tests-rks-upcase-fallback)
(keyboard-tests-rks-no-upcase-fallback)
(keyboard-tests-rks-dont-downcase-last)
(keyboard-tests-rks-shifted-function-key-fallback)
(keyboard-tests-rks-switch-frame-delayed)
(keyboard-tests-rks-unbound-down-mouse-dropped)
(keyboard-tests-rks-mode-line-fake-prefix)
(keyboard-tests-rks-mode-line-fake-prefix-continued)
(keyboard-tests-rks-clicked-buffer-switch)
(keyboard-tests-rks-help-char): Tests covering for read_key_sequence.
2026-04-29 23:31:29 -04:00
Eli Zaretskii
7017fcc4c5 ; Add new test to files-tests
* test/lisp/files-tests.el
(files-tests-directory-files-recursively-w32): New test.
2026-04-29 18:04:48 +03:00
Eli Zaretskii
08a22b8965 ; Don't skip 'vc-test-src-version-diff' test
* test/lisp/vc/vc-tests/vc-tests.el (vc-test-src-version-diff):
Don't skip, it passes.
2026-04-27 15:47:57 +03:00
Eli Zaretskii
8d4c47c880 Fix vc-tests for SRC
* lisp/vc/vc-src.el (vc-src-register): Support "registering"
directories in FILES.
(vc-src-rename-file): Fix implementation and support renaming
directories.

* test/lisp/vc/vc-tests/vc-tests.el (vc-test--rename-file)
(vc-test-src-version-diff): Skip parts that don't work with SRC.
(Bug#80862)
2026-04-27 15:41:27 +03:00
Philip Kaludercic
e83052c095
Add lexical-binding cookies to multi-file-0.2.3.tar
* test/lisp/emacs-lisp/package-resources/multi-file-0.2.3.tar:
Update multi-file.el and multi-file-sub.el files.
2026-04-27 11:48:58 +02:00
Yuan Fu
9e70acea67
Fix tree-sitter embedded parser range
If a host parser has some ranges, and an embedded parser also
has some ranges, the final range used by the embedded parser
should be an intersection of the two.  This patch adds this
logic.

* lisp/treesit.el (treesit--range-verbose): New variable.
(treesit--intersect-ranges):
(treesit--set-embed-ranges): New function.
(treesit--update-ranges-non-local):
(treesit--update-ranges-local): Use the new functions.
* test/src/treesit-tests.el:
(treesit-intersect-ranges): New test.
2026-04-27 02:14:49 -07:00
Stefan Monnier
4bd5608513 (register--get-method-type): Fix one more case (bug#80894)
* lisp/register.el (register--get-method-type): Refine the cl-generic hack
yet a but further.
* test/lisp/register-tests.el (register--jumpable-p): Fix the test.
2026-04-26 12:18:44 -04:00
Aaron L. Zeng
e4633e657a Support Elisp debugging and backtraces in code called by modules
* src/lisp.h (handlertype) <CATCHER_ALL_DEBUGGABLE>: New enumeration
value.
* src/emacs-module.c (MODULE_HANDLE_NONLOCAL_EXIT):
* src/eval.c (Fthrow, signal_or_quit): Use it.

* test/src/emacs-module-tests.el
(mod-test-non-local-exit-funcall-debug-on-error): New test.

Bug#80714

Copyright-paperwork-exempt: yes.
2026-04-26 15:20:28 +03:00
Eli Zaretskii
bbdab523b4 Fix renaming files and directories under RCS
* lisp/vc/vc-rcs.el (vc-rcs-register): Filter out directories from
FILES.
(vc-rcs-rename-file): Support OLD being a directory.

* test/lisp/vc/vc-tests/vc-tests.el (vc-test--rename-file)
(vc-test--rename-directory): Re-enable these tests for RCS.
(vc-test--rename-directory): Disable 'yes-or-no-p' questions that
RCS asks when it needs to create the RCS/ subdirectory: this lets
the test run without user interaction.
2026-04-26 14:20:56 +03:00
Eli Zaretskii
6a39de6ee5 ; Add more register tests
* test/lisp/register-tests.el (register--jumpable-p): Add tests
for more register types.  (Bug#80894)
2026-04-26 11:34:39 +03:00
Yuan Fu
d3debef28d
Make :range-fn in treesit-range-rules actually work
* lisp/treesit.el (treesit--range-start):
(treesit--range-end):
(treesit--flatten-ranges): New helpers.
(treesit-query-range):
(treesit-query-range-by-language): Don't flatten the ranges
returned by each range-fn.
(treesit--update-ranges-non-local):
(treesit--update-ranges-local): Handle the case where the range
is a complicated ((START . END)...).
* test/src/treesit-tests.el (treesit-range-helper): New test.
2026-04-25 10:49:26 -07:00
Stefan Monnier
28f828e8a6 register.el: Allow jumping to kmacros again (bug#80894)
* lisp/register.el (register--get-method-type): Fix handling for
OClosure args.
* test/lisp/register-tests.el (register--jumpable-p): New test.
2026-04-25 10:41:16 -04:00
Michael Albinus
aa067441d6 Some minor Tramp fixes
* doc/misc/tramp.texi (Customizing Methods): Add comment.

* lisp/net/tramp-sh.el (tramp-open-connection-setup-interactive-shell):
Comment out setting `command-line-max-length', it doesn't work reliably.

* test/lisp/net/tramp-tests.el (tramp-test03-file-error)
(tramp-test26-file-name-completion-boundaries): Adapt tests.
2026-04-25 10:01:37 +02:00
Sean Whitton
0a04a4bc7a vc-hg-after-dir-status: Rewrite to handle current 'hg status' output
* lisp/vc/vc-hg.el (vc-hg-after-dir-status): Rewrite to handle
renames where the "R" line comes arbitrarily later in the
output.
* test/lisp/vc/vc-hg-tests.el
(vc-hg-test--after-dir-status-expect): New function.
(vc-hg-after-dir-status): New test.
2026-04-23 15:27:20 +01:00
Philip Kaludercic
986892fe30
; Adjust package tests for 789e98e54f
* test/lisp/emacs-lisp/package-tests.el (package-test-get-deps):
Replace test with an analogous test for 'package--dependencies'.
2026-04-22 20:46:33 +02:00
Roi Martin
7f1e54c61a Test that ERT creates a list of executed tests from erts files
* test/lisp/emacs-lisp/ert-resources/erts-file-test-list-fail.erts:
* test/lisp/emacs-lisp/ert-resources/erts-file-test-list.erts: New erts
files.
* test/lisp/emacs-lisp/ert-tests.el (ert-test-list-of-erts-file-tests):
New test.
2026-04-22 18:03:47 +02:00
Eli Zaretskii
6f15481be5 ; Fix files-tests on MS-Windows
* test/lisp/files-tests.el
(files-tests-file-name-non-special--temp-file-prefixes): Don't use
a file name with '*' on MS-Windows.
2026-04-22 08:48:49 +03:00