<feed xmlns='http://www.w3.org/2005/Atom'>
<title>emacs/test/lisp/replace-tests.el, branch features/user-directory</title>
<subtitle>Emacs is the extensible, customizable, self-documenting real-time display editor. 
</subtitle>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/'/>
<entry>
<title>Keep track of match extents in occur-mode (bug#39121)</title>
<updated>2021-07-25T08:29:09+00:00</updated>
<author>
<name>Mattias Engdegård</name>
</author>
<published>2021-07-24T14:32:11+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=c52e26df30d5679dc2b9b34853a3c2db062524ac'/>
<id>c52e26df30d5679dc2b9b34853a3c2db062524ac</id>
<content type='text'>
Use the `occur-target` text property to keep track of the extents of
all matches on each line instead of just the start of the first match.
Doing so allows us to highlight all matches when jumping to a matching
line instead of just the first one, and it works in a more principled
way.  It also removes compatibility problems that were introduced with
occur-highlight-regexp.

For compatibility with code that populate their own occur-mode
buffers, we still accept `occur-target` properties with a single
marker as value.

* lisp/replace.el (occur-highlight-regexp, occur-highlight-overlay):
Remove.
(occur-highlight-overlays): New.
(occur--targets-start): New.
* lisp/replace.el (occur-after-change-function):
(occur-mode-find-occurrence): Replace with...
(occur-mode--find-occurrences): ...this function that returns the
whole `occur-target` property value.
(occur-mode-goto-occurrence, occur-mode-goto-occurrence-other-window)
(occur-goto-locus-delete-o, occur-mode-display-occurrence)
(occur-engine): Adjust to new property format.
(occur--highlight-occurrence): Replace with...
(occur--highlight-occurrences): ...this function that takes
the `occur-target` property value as argument.
(occur-1): Don't use `occur-highlight-regexp`.
* test/lisp/replace-tests.el (occur-highlight-occurrence):
Adapt to new property format.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use the `occur-target` text property to keep track of the extents of
all matches on each line instead of just the start of the first match.
Doing so allows us to highlight all matches when jumping to a matching
line instead of just the first one, and it works in a more principled
way.  It also removes compatibility problems that were introduced with
occur-highlight-regexp.

For compatibility with code that populate their own occur-mode
buffers, we still accept `occur-target` properties with a single
marker as value.

* lisp/replace.el (occur-highlight-regexp, occur-highlight-overlay):
Remove.
(occur-highlight-overlays): New.
(occur--targets-start): New.
* lisp/replace.el (occur-after-change-function):
(occur-mode-find-occurrence): Replace with...
(occur-mode--find-occurrences): ...this function that returns the
whole `occur-target` property value.
(occur-mode-goto-occurrence, occur-mode-goto-occurrence-other-window)
(occur-goto-locus-delete-o, occur-mode-display-occurrence)
(occur-engine): Adjust to new property format.
(occur--highlight-occurrence): Replace with...
(occur--highlight-occurrences): ...this function that takes
the `occur-target` property value as argument.
(occur-1): Don't use `occur-highlight-regexp`.
* test/lisp/replace-tests.el (occur-highlight-occurrence):
Adapt to new property format.
</pre>
</div>
</content>
</entry>
<entry>
<title>Disable delay and ding in replace-tests</title>
<updated>2021-07-24T17:30:39+00:00</updated>
<author>
<name>Mattias Engdegård</name>
</author>
<published>2021-07-24T15:11:21+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=03f844249cb15a8380d09041a537803c933a2769'/>
<id>03f844249cb15a8380d09041a537803c933a2769</id>
<content type='text'>
* test/lisp/replace-tests.el (replace-tests-with-undo):
When testing the "U" (undo all changes) option, the code will delay
and ding which is obnoxious in an automated test.
Disabling that makes the test quiet and about 150 times faster.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* test/lisp/replace-tests.el (replace-tests-with-undo):
When testing the "U" (undo all changes) option, the code will delay
and ding which is obnoxious in an automated test.
Disabling that makes the test quiet and about 150 times faster.
</pre>
</div>
</content>
</entry>
<entry>
<title>Count zero-length matches in `count-matches' correctly</title>
<updated>2021-07-05T14:30:43+00:00</updated>
<author>
<name>Lars Ingebrigtsen</name>
</author>
<published>2021-07-05T14:30:43+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=a111978de8fa28256a208d823b68a37188dfa7f0'/>
<id>a111978de8fa28256a208d823b68a37188dfa7f0</id>
<content type='text'>
* lisp/replace.el (how-many): Count zero-length matches correctly
(bug#27359).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* lisp/replace.el (how-many): Count zero-length matches correctly
(bug#27359).
</pre>
</div>
</content>
</entry>
<entry>
<title>test/lisp/replace-tests.el: Add nested match group test</title>
<updated>2021-01-20T01:46:17+00:00</updated>
<author>
<name>Nick Drozd</name>
</author>
<published>2021-01-20T01:46:17+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=5536893c6e629d9541c75a1b0b239eaa96c6eaeb'/>
<id>5536893c6e629d9541c75a1b0b239eaa96c6eaeb</id>
<content type='text'>
* test/lisp/replace-tests.el (replace-regexp-bug45973): Add test
(bug#45973).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* test/lisp/replace-tests.el (replace-regexp-bug45973): Add test
(bug#45973).
</pre>
</div>
</content>
</entry>
<entry>
<title>Update copyright year to 2021</title>
<updated>2021-01-01T09:13:56+00:00</updated>
<author>
<name>Paul Eggert</name>
</author>
<published>2021-01-01T09:13:56+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=ba05d005e5a81bc123ad8da928b1bccb6b160e7a'/>
<id>ba05d005e5a81bc123ad8da928b1bccb6b160e7a</id>
<content type='text'>
Run "TZ=UTC0 admin/update-copyright".
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Run "TZ=UTC0 admin/update-copyright".
</pre>
</div>
</content>
</entry>
<entry>
<title>occur: Add bindings for next-error-no-select</title>
<updated>2020-05-31T10:31:27+00:00</updated>
<author>
<name>Tino Calancha</name>
</author>
<published>2020-05-31T10:31:27+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=abe7c22da96694ced1bc80ec7eb9eb8a662a568b'/>
<id>abe7c22da96694ced1bc80ec7eb9eb8a662a568b</id>
<content type='text'>
Make the navigation in the occur buffer closer
to the navigation in the compilation buffer.

Add bindings to navigate the occur matches (Bug#39121).
Honor `next-error-highlight' and `next-error-highlight-no-select'
when navigating the occurrences.

* lisp/replace.el (occur-highlight-regexp, occur-highlight-overlay):
New variables.
(occur-1): Set `occur-highlight-regexp' to the searched regexp.
(occur-goto-locus-delete-o, occur--highlight-occurrence): New defuns.
(occur-mode-display-occurrence, occur-mode-goto-occurrence):
Use `occur--highlight-occurrence'.
(occur-mode-map): Bind n to `next-error-no-select'
and p to `previous-error-no-select'

* etc/NEWS (Changes in Specialized Modes and Packages in Emacs 28.1):
Announce this change.

* test/lisp/replace-tests.el (replace-tests-with-highlighted-occurrence):
Add helper macro.
(occur-highlight-occurrence): Add test.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Make the navigation in the occur buffer closer
to the navigation in the compilation buffer.

Add bindings to navigate the occur matches (Bug#39121).
Honor `next-error-highlight' and `next-error-highlight-no-select'
when navigating the occurrences.

* lisp/replace.el (occur-highlight-regexp, occur-highlight-overlay):
New variables.
(occur-1): Set `occur-highlight-regexp' to the searched regexp.
(occur-goto-locus-delete-o, occur--highlight-occurrence): New defuns.
(occur-mode-display-occurrence, occur-mode-goto-occurrence):
Use `occur--highlight-occurrence'.
(occur-mode-map): Bind n to `next-error-no-select'
and p to `previous-error-no-select'

* etc/NEWS (Changes in Specialized Modes and Packages in Emacs 28.1):
Announce this change.

* test/lisp/replace-tests.el (replace-tests-with-highlighted-occurrence):
Add helper macro.
(occur-highlight-occurrence): Add test.
</pre>
</div>
</content>
</entry>
<entry>
<title>Use lexical-binding in most remaining tests</title>
<updated>2020-05-01T11:05:26+00:00</updated>
<author>
<name>Stefan Kangas</name>
</author>
<published>2020-05-01T11:02:38+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=7fa3e754cb7af37b0c50f253e7dec2acd0275a8a'/>
<id>7fa3e754cb7af37b0c50f253e7dec2acd0275a8a</id>
<content type='text'>
* test/lisp/comint-tests.el:
* test/lisp/custom-resources/custom--test-theme.el:
* test/lisp/dabbrev-tests.el:
* test/lisp/emulation/viper-tests.el:
* test/lisp/erc/erc-track-tests.el:
* test/lisp/gnus/gnus-tests.el:
* test/lisp/imenu-tests.el:
* test/lisp/info-xref-tests.el:
* test/lisp/jit-lock-tests.el:
* test/lisp/json-tests.el:
* test/lisp/man-tests.el:
* test/lisp/replace-tests.el:
* test/lisp/shadowfile-tests.el:
* test/lisp/subr-tests.el:
* test/lisp/thingatpt-tests.el:
* test/lisp/xml-tests.el: Use lexical-binding.

* test/lisp/man-tests.el (man-tests-filter-strings):
* test/lisp/shadowfile-tests.el (shadow-test00-clusters)
(shadow-test01-sites, shadow-test06-literal-groups)
(shadow-test07-regexp-groups, shadow-test09-shadow-copy-files):
Silence byte-compiler.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* test/lisp/comint-tests.el:
* test/lisp/custom-resources/custom--test-theme.el:
* test/lisp/dabbrev-tests.el:
* test/lisp/emulation/viper-tests.el:
* test/lisp/erc/erc-track-tests.el:
* test/lisp/gnus/gnus-tests.el:
* test/lisp/imenu-tests.el:
* test/lisp/info-xref-tests.el:
* test/lisp/jit-lock-tests.el:
* test/lisp/json-tests.el:
* test/lisp/man-tests.el:
* test/lisp/replace-tests.el:
* test/lisp/shadowfile-tests.el:
* test/lisp/subr-tests.el:
* test/lisp/thingatpt-tests.el:
* test/lisp/xml-tests.el: Use lexical-binding.

* test/lisp/man-tests.el (man-tests-filter-strings):
* test/lisp/shadowfile-tests.el (shadow-test00-clusters)
(shadow-test01-sites, shadow-test06-literal-groups)
(shadow-test07-regexp-groups, shadow-test09-shadow-copy-files):
Silence byte-compiler.
</pre>
</div>
</content>
</entry>
<entry>
<title>Update copyright year to 2020</title>
<updated>2020-01-01T00:59:52+00:00</updated>
<author>
<name>Paul Eggert</name>
</author>
<published>2020-01-01T00:19:43+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=365e01cc9f64ce6ca947ccfd8612d60763280a37'/>
<id>365e01cc9f64ce6ca947ccfd8612d60763280a37</id>
<content type='text'>
Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge from origin/emacs-26</title>
<updated>2019-09-15T23:38:23+00:00</updated>
<author>
<name>Glenn Morris</name>
</author>
<published>2019-09-15T23:38:23+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=a625ca5c2675a41c5c0d277def6b8cb4f4c4d6db'/>
<id>a625ca5c2675a41c5c0d277def6b8cb4f4c4d6db</id>
<content type='text'>
30c4f35 (origin/emacs-26) query-replace-regexp undo: Update next-repl...
c596be0 Amend the menu caption for page "Display Property" in the Eli...
13b9510 Add description of chinese-sisheng
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
30c4f35 (origin/emacs-26) query-replace-regexp undo: Update next-repl...
c596be0 Amend the menu caption for page "Display Property" in the Eli...
13b9510 Add description of chinese-sisheng
</pre>
</div>
</content>
</entry>
<entry>
<title>query-replace-regexp undo: Update next-replacement after undo</title>
<updated>2019-09-09T06:21:18+00:00</updated>
<author>
<name>Tino Calancha</name>
</author>
<published>2019-09-09T06:21:18+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=30c4f35a6fc8a6507930923766c3126ac1c2063f'/>
<id>30c4f35a6fc8a6507930923766c3126ac1c2063f</id>
<content type='text'>
* lisp/replace.el (perform-replace):
Rename the local binding to not shadow next-replacement.
Update next-replacement after undo (Bug#37287).

* test/lisp/replace-tests.el (query-replace-undo-bug37287): Add test.
(query-replace-undo-bug37073): Tweak this test.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* lisp/replace.el (perform-replace):
Rename the local binding to not shadow next-replacement.
Update next-replacement after undo (Bug#37287).

* test/lisp/replace-tests.el (query-replace-undo-bug37287): Add test.
(query-replace-undo-bug37073): Tweak this test.
</pre>
</div>
</content>
</entry>
</feed>
