1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-22 07:09:54 +00:00
Commit Graph

222 Commits

Author SHA1 Message Date
Stefan Kangas
920a7d38e9 ; Fix typos 2023-01-15 02:14:19 +01:00
Eli Zaretskii
cae528457c ; Add 2023 to copyright years. 2023-01-01 05:31:12 -05:00
Stefan Kangas
70ecdebc92 ; Fix typos (don't abbreviate "with" or "without") 2022-12-01 16:36:09 +01:00
Eli Zaretskii
89a10ffcc4 Fix the new ctags test
* test/manual/etags/Makefile (ctags_update): Sort CTAGS* files
before comparing.  Patch by lu4nx <lx@shellcodes.org>.  (Bug#59544)

* .gitignore: Ignore CTAGS*.sorted files.
2022-11-27 20:01:50 +02:00
Eli Zaretskii
6f0906be51 ; Fix last change in etags.c
* lib-src/etags.c (cleanup_tags_file): Renamed from
clean_matched_file_tag.

* test/manual/etags/CTAGS.good_update:
* test/manual/etags/CTAGS.good_crlf: Update to match the test.
2022-11-27 15:43:39 +02:00
lu4nx
d48bb4874b Fixed ctags local command execute vulnerability
* lib-src/etags.c:

(clean_matched_file_tag): New function
(do_move_file): New function
(readline_internal):
Add `leave_cr` parameter, if true, include the \r character

* test/manual/etags/CTAGS.good_crlf: New file
* test/manual/etags/CTAGS.good_update: New file
* test/manual/etags/crlf: New file
* test/manual/etags/Makefile: Add `ctags -u` test cases
2022-11-27 15:20:49 +02:00
Stefan Kangas
ba485eb949 ; Fix typos 2022-11-18 16:02:19 +01:00
Basil L. Contovounesios
fd3f51b7c3 Fix manual noverlay tests
* test/manual/noverlay/Makefile.in: Add copyright notice.
(LIBS): Rename...
(PACKAGES): ...to this, to avoid confusion with Autoconf's LIBS.
All uses changed.
(CFLAGS): Break out -I flag...
(CPPFLAGS): ...into this new variable.
(LDFLAGS): Rename...
(LDLIBS): ...to this, which is expected to hold -l flags.
(top_builddir): New variable.
(EMACS): Define in terms of it.
(.PHONY): Add clean, distclean, and perf targets.
(have-libcheck): Remove redundant target.  All uses updated.
(itree-tests.o): Remove redundant dependency on its source file.
(itree-tests): Remove redundant (and uncompilable) rule.

* test/manual/noverlay/check-sanitize.sh: Use /usr/bin/env.  Add
copyright notice.  Enable pipefail option, to propagate itree-tests
exit status to caller.  Fix typo in usage message.  Strip less
information from Check's error messages.

* test/manual/noverlay/emacs-compat.h: Add copyright notice.
Include stdlib.h.
(emacs_abort, eassert): Consistently use EXIT_FAILURE.
(eassume): Define when necessary.

* test/manual/noverlay/itree-tests.c: Add copyright notice.  Include
standard headers before third-party ones.  Use most narrowly
applicable ck_assert* macro for the types being checked,
e.g. ck_assert_ptr_* macros for pointer values.  Replace removed
names and APIs with current ones, e.g. the itree_node field 'color'
is now called 'red'.  Ensure preconditions of itree API are
satisfied before use, e.g. itree_node otick being set appropriately
before insertion, or global iterator being initialized
before (implicit) use (bug#58976).  Make all functions static.
(DEF_TEST_SETUP): Remove all instances, replacing with...
(test_insert1_setup, test_insert2_setup, test_remove1_setup)
(test_remove2_setup): ...these new test fixtures.
(A, B, C, D, E, N_05, N_10, N_15, N_20, N_30, N_40, N_50, N_70)
(N_80, N_90, N_85, N_95): Define as static variables rather than
macros.
(test_get_tree4): Remove, inlining salient parts.
(shuffle): Move closer to users.
(test_create_tree): Accept itree_nodes as argument instead of
dynamically allocating them.  All callers changed.
(FOREACH): Remove unused macro.
(N_BEG, N_END): Define in terms of itree_node_begin and
itree_node_end, respectively.
(test_gap_insert_1, test_gap_insert_2, test_gap_insert_3)
(test_gap_insert_5, test_gap_insert_7, test_gap_insert_11): Use
test_setup_gap_node_noadvance.
(basic_suite): Group unit tests into test cases and fixtures.  Run
previously forgotten test_insert_14.
(main): Run suite as CK_ENV to allow specifying desired verbosity in
the environment.
2022-11-04 13:38:02 +02:00
Stefan Monnier
71589b101c Merge remote-tracking branch 'origin/feature/noverlay' 2022-10-28 17:44:44 -04:00
Basil L. Contovounesios
f5c6e628ed Update image-circular-tests.el
* test/manual/image-circular-tests.el
(image-test-duplicate-keywords): Skip unless images are supported.
(image-test-circular-plist, image-test-:type-property-value): Ditto.
Wrap only failing forms in should[-error] rather than entire test
bodies.  Use simpler printed notation in place of function calls.
(image-test-circular-specs): Ditto.  Wrap overly wide docstring.
Mark as failing since shortly after its introduction (bug#36403#63).
2022-10-15 01:10:31 +03:00
Eli Zaretskii
db6072f530 Revert "Improve manual display tests of undisplayable chars (bug#58168)"
This reverts commit 849b7756fd.
Please don't rush installing changes that are still being
discussed.
2022-10-04 19:15:17 +03:00
Mattias Engdegård
849b7756fd Improve manual display tests of undisplayable chars (bug#58168)
Test display of multibyte raw bytes, as well as undisplayable
multibyte chars (C1 controls and other values).

The test still assumes that raw bytes should be displayed identically
to undisplayable characters (such as C1 controls) because that is how
the display code currently works.

* test/manual/redisplay-testsuite.el (test-redisplay-5-toggle)
(test-redisplay-5): Fix likely typo (#x3fffc) of raw byte value.
(test-redisplay-6): New.
2022-10-04 16:44:34 +02:00
Stefan Monnier
650c20f1ca Merge 'master' into noverlay 2022-09-25 16:15:16 -04:00
समीर सिंह Sameer Singh
8ec7f8f169 Update Unicode support to Unicode version 15.0.0 (bug#57846)
* admin/unidata/BidiBrackets.txt
* admin/unidata/BidiMirroring.txt
* admin/unidata/Blocks.txt
* admin/unidata/IVD_Sequences.txt
* admin/unidata/IdnaMappingTable.txt
* admin/unidata/NormalizationTest.txt
* admin/unidata/PropertyValueAliases.txt
* admin/unidata/ScriptExtensions.txt
* admin/unidata/Scripts.txt
* admin/unidata/SpecialCasing.txt
* admin/unidata/UnicodeData.txt
* admin/unidata/confusables.txt
* admin/unidata/copyright.html
* admin/unidata/emoji-data.txt
* admin/unidata/emoji-sequences.txt
* admin/unidata/emoji-test.txt
* admin/unidata/emoji-zwj-sequences.txt
* test/manual/BidiCharacterTest.txt: Updated files from Unicode
15.0.

* admin/unidata/unidata-gen.el (unidata-file-alist): Add new ranges.

* lisp/international/fontset.el (script-representative-chars): Add
new scripts.
(otf-script-alist): Update from latest version.
(setup-default-fontset): Add new scripts.
* lisp/international/characters.el: Update syntax and category
tables for new characters and scripts.
(char-width-table): Update for changes in Unicode 15.0.

* test/lisp/international/ucs-normalize-tests.el
(ucs-normalize-tests--failing-lines-part1)
(ucs-normalize-tests--failing-lines-part2): Update per the test
results.

* doc/lispref/nonascii.texi (Character Properties): Update Unicode
version number.

* etc/NEWS: Announce support for Unicode 15.0.
2022-09-17 09:51:22 +03:00
dickmao
dd22694421 Avoid double svg error reporting and segfaults
* src/image.c (svg_load_image): Use g_error_free directly instead
of the helder g_clear_error (since we're only calling it with
non-nil values).
(svg_load_image): Avoid segfault and double reporting errors.
* test/manual/image-tests.el (image-tests-load-image/svg-too-big)
(image-tests-load-image/svg-invalid): Test it (bug#57755).
2022-09-13 13:57:44 +02:00
Stefan Kangas
89199f16ae ; Fix last change in test/manual/image-tests.el
* test/manual/image-tests.el (image-skip-unless):
(image-tests-image-metadata/gif): Fix last change.
2022-09-13 11:06:40 +02:00
Stefan Kangas
8253090293 Skip manual GIF metadata test on MS-Windows
* test/manual/image-tests.el
(image-skip-unless): Add new arg CONDITION.
(image-tests-image-metadata/gif): Skip test on MS-Windows when
using native image API.  (Bug#57691)
2022-09-12 15:15:16 +02:00
Stefan Kangas
72c64dd73c Fix SVG loading test for old librsvg 2.40.1
* test/manual/image-tests.el (image-tests-load-image/svg-invalid): Fix
test for old librsvg 2.40.1.  (Bug#57691)
2022-09-09 14:24:51 +02:00
Stefan Kangas
0ad028c91f ; Clean up recently added SVG test
* test/manual/image-tests.el (image-tests-load-image/svg-invalid):
Clean up.
2022-09-09 14:20:29 +02:00
Stefan Kangas
816106b7e6 Display librsvg error when loading bad SVG
* src/image.c (svg_load_image): Display the error message from librsvg
when parsing a bad SVG image file.
* test/manual/image-tests.el
(image-tests-load-image/svg-invalid): New test.
2022-09-09 03:07:44 +02:00
Stefan Kangas
5b87429d99 Move some tests to test/manual/image-tests.el
* test/src/image-tests.el: Move several tests from here...
* test/manual/image-tests.el: ...to here.
Suggested by Eli Zaretskii <eliz@gnu.org>.
2022-09-08 02:35:37 +02:00
Stefan Kangas
9ea513134b Update the 'etags' test suite
* ETAGS.good_1:
* ETAGS_good_2:
* ETAGS_good_3:
* ETAGS_good_4:
* ETAGS_good_5:
* ETAGS_good_6: Adapt to recent changes in test sources.
2022-07-14 12:52:32 +02:00
Stefan Kangas
41e612cfd6 ; Fix typos 2022-07-14 12:52:32 +02:00
Lars Ingebrigtsen
061de95d59 Don't call home from test/src/process-tests.el
* test/src/process-tests.el (process-num-processors): Move from
here...
* test/manual/process-callout-tests.el: ... to here (bug#55858).
2022-07-11 13:19:48 +02:00
Lars Ingebrigtsen
bd0b96d252 Allow using :width/:height as normal with xbm images
* doc/lispref/display.texi (XBM Images): Adjust the documentation.
* src/image.c (enum xbm_keyword_index): Add :data-width and
:data-height.
(xbm_format): Ditto.
(xbm_image_p): Allow passing in :width/:height for display.
(xbm_load): Use :data-width/:data-height.
2022-06-20 11:18:31 +02:00
Eli Zaretskii
8ef3862fa0 Update the 'etags' test suite
* ETAGS.good_1:
* ETAGS_good_2:
* ETAGS_good_3:
* ETAGS_good_4:
* ETAGS_good_5:
* ETAGS_good_6: Adapt to recent changes in test sources.

* lib-src/etags.c (C_entries): Add commentary for resetting
bracelev.  (Bug#45246)
2022-06-09 20:33:43 +03:00
Lars Ingebrigtsen
b2bce107b1 Further audits of single quotes in Lisp doc strings
* test/manual/etags/el-src/emacs/lisp/progmodes/etags.el
(tags-apropos-additional-actions):
* lisp/window.el (delete-window-choose-selected):
* lisp/vc/ediff-merg.el (ediff-combination-pattern):
* lisp/vc/diff.el (diff-no-select):
* lisp/tab-bar.el (tab-bar-new-tab-choice):
* lisp/simple.el (next-error-message-highlight):
(backward-delete-char-untabify):
* lisp/ses.el (ses-jump-cell-name-function):
* lisp/org/org.el (org-latex-to-html-convert-command):
* lisp/org/org-agenda.el (org-agenda-sorting-strategy):
* lisp/net/tramp.el (tramp-default-file-modes):
* lisp/net/newst-treeview.el
(newsticker-treeview-use-feed-name-from-url-list-in-treeview):
* lisp/net/eww.el (eww-auto-rename-buffer):
* lisp/mwheel.el (mouse-wheel-scroll-amount):
* lisp/mail/rmail.el (rmail-re-abbrevs):
* lisp/info.el (Info-history-forward-menu):
* lisp/gnus/nnselect.el (nnselect-retrieve-headers-override-function):
* lisp/gnus/gnus-start.el (gnus-subscribe-hierarchical-interactive):
* lisp/fringe.el (fboundp):
* lisp/eshell/esh-var.el (eshell-variable-aliases-list):
* lisp/emacs-lisp/checkdoc.el (checkdoc-column-zero-backslash-before-paren):
* lisp/dired-aux.el (dired-confirm-shell-command):
* lisp/calendar/calendar.el (calendar-time-zone-style):
* lisp/ansi-color.el (ansi-color-faces-vector):
(ansi-color-names-vector): Audit use of various single quotes in
Lisp doc strings.
2022-05-24 13:17:53 +02:00
Lars Ingebrigtsen
59951f7af5 Audit quoting symbols in C doc strings
* test/manual/etags/c-src/emacs/src/keyboard.c (Frecursive_edit):
* src/xfns.c (syms_of_xfns):
* src/xdisp.c (Fwindow_text_pixel_size):
(syms_of_xdisp):
* src/w32notify.c (Fw32notify_add_watch):
(Fw32notify_add_watch):
* src/frame.c (Fframe_child_frame_border_width):
* src/comp.c (Fcomp__subr_signature):
* src/alloc.c (Fgarbage_collect):
* lib-src/make-docfile.c (scan_c_stream): Audit quoting symbols in C
doc strings.
2022-05-24 11:51:18 +02:00
Eli Zaretskii
dcd76bd48d Merge from origin/emacs-28
836be7a112 ; * etc/refcards/ru-refcard.tex: Update Copyright year.
86cbc6ee4a * lisp/net/tramp-sh.el: Adapt copyright year
ebe8772f65 ; Minor fixes related to copyright years
23c1ee6989 ; * test/manual/etags/ETAGS.good_N: Adjust to copyright ye...
8d3fc7ec89 * src/xfaces.c (face_for_font): Make 'hash' be uintptr_t.
19dcb237b5 ; Add 2022 to copyright years.

# Conflicts:
#	etc/NEWS
#	etc/refcards/ru-refcard.tex
#	lib/cdefs.h
#	lisp/erc/erc-dcc.el
#	lisp/erc/erc-imenu.el
#	lisp/erc/erc-replace.el
#	lisp/image-dired.el
#	lisp/progmodes/xref.el
#	m4/alloca.m4
#	m4/byteswap.m4
#	m4/errno_h.m4
#	m4/getopt.m4
#	m4/gnulib-common.m4
#	m4/inttypes.m4
#	m4/stddef_h.m4
#	m4/stdint.m4
#	m4/sys_socket_h.m4
2022-01-01 07:03:03 -05:00
Eli Zaretskii
23c1ee6989 ; * test/manual/etags/ETAGS.good_N: Adjust to copyright years change. 2022-01-01 05:19:17 -05:00
Eli Zaretskii
19dcb237b5 ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
Stefan Monnier
13ef21e84a Fix EIEIO tests to account for eieio-compat move
* test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el:
* test/lisp/emacs-lisp/eieio-tests/eieio-tests.el:
Require `eieio-compat` explicitly.

* test/manual/cedet/tests/test.el (a-method, a-generic):
* doc/misc/srecode.texi (Compound Dictionary Values):
* doc/misc/ede.texi (ede-generic-project): Update sample code to use
cl-generic syntax.
2021-12-27 17:24:52 -05:00
Stefan Kangas
f522a064cf perl-mode: Recognize "when"/"given" keywords
* lisp/progmodes/perl-mode.el (perl-font-lock-keywords-2): Add
keywords "when", "given" and "default".  (Bug#10560)
(perl--syntax-exp-intro-keywords): Add "printf".

* test/manual/indent/perl.perl: Add test for "when"/"given".
2021-12-27 03:19:25 +01:00
Paul Eggert
af60618945 Simplify cedet-utest-elapsed-time
* test/manual/cedet/cedet-utests.el (cedet-utest-elapsed-time):
Copy newer (circa-2011) implementation from elp.el, so that the
code matches its documentation again.
2021-12-05 23:24:08 -08:00
Stefan Kangas
8bb28e740d ; Minor stylistic checkdoc fixes in test/**/*.el 2021-09-26 17:53:23 +02:00
Stefan Kangas
63f419f133 ; Minor stylistic fixes found by checkdoc 2021-09-16 19:37:07 +02:00
Eli Zaretskii
83557511a7 Update Unicode support to Unicode version 14.0.0
* admin/unidata/copyright.html:
* admin/unidata/UnicodeData.txt:
* admin/unidata/Blocks.txt:
* admin/unidata/BidiBrackets.txt:
* admin/unidata/BidiMirroring.txt:
* admin/unidata/IVD_Sequences.txt:
* admin/unidata/NormalizationTest.txt:
* admin/unidata/SpecialCasing.txt:
* test/manual/BidiCharacterTest.txt: Updated files from Unicode
14.0.

* lisp/international/fontset.el (script-representative-chars): Add
new scripts.
(otf-script-alist): Update from latest version.
(setup-default-fontset): Add new scripts.
* lisp/international/characters.el: Update syntax and category
tables for new characters and scripts.
(char-width-table): Update for changes in Unicode 14.0.
* lisp/international/mule-cmds.el (ucs-names): Update used and
unused ranges per Unicode 14.0.

* test/lisp/international/ucs-normalize-tests.el
(ucs-normalize-tests--failing-lines-part1)
(ucs-normalize-tests--failing-lines-part2): Update per the test
results.

* doc/lispref/nonascii.texi (Character Properties): Update Unicode
version number.

* etc/NEWS: Announce support for Unicode 14.0.

* admin/notes/unicode: Minor copyedits.
2021-09-15 14:40:13 +03:00
Eli Zaretskii
6af9f1f3ef Improve and update the 'etags' test suite
* lib-src/etags.c (mercury_pr): Remove redundant comment.

* test/manual/etags/merc-src/accumulator.m: Add more complex
declarations.
* test/manual/etags/ETAGS.good_1:
* test/manual/etags/ETAGS.good_2:
* test/manual/etags/ETAGS.good_3:
* test/manual/etags/ETAGS.good_4:
* test/manual/etags/ETAGS.good_5:
* test/manual/etags/ETAGS.good_6:
* test/manual/etags/CTAGS.good: Adapt to latest changes in 'etags'
and the test suite.  (Bug#47408)
2021-06-18 14:28:16 +03:00
Philipp Stephani
bc44763b83 Update SCSS test file syntax.
According to
https://sass-lang.com/documentation/breaking-changes/slash-div, the
slash operator should be replaced by 'math.div'.

Fixed using the migration tool mentioned at
https://sass-lang.com/documentation/breaking-changes/slash-div#automatic-migration.

* test/manual/indent/scss-mode.scss: Remove slash operator.
2021-06-18 08:32:55 +02:00
Eli Zaretskii
af4cccb8d9 Support mercury in 'ctags' as well
The previous lack of support was due to incorrect calls to 'make_tag'
in 'mercury_pr', which caused 'pfnote' to refrain from adding Mercury
tags to the list of recorded tags.

* lib-src/etags.c (mercury_pr): Pass the correct NAME and NAMELEN
arguments to 'make_tag'.

* test/manual/etags/CTAGS.good: Adjust to the above change.
2021-06-10 16:57:03 +03:00
Eli Zaretskii
6ef5760b10 Minor fixes for last change
* test/manual/etags/ETAGS.good_1:
* test/manual/etags/ETAGS.good_2:
* test/manual/etags/ETAGS.good_3:
* test/manual/etags/ETAGS.good_4:
* test/manual/etags/ETAGS.good_5:
* test/manual/etags/ETAGS.good_6: Adapt to added Mercury support.

* lib-src/etags.c (find_entries, test_objc_is_mercury):
* etc/NEWS: Fix punctuation and typos in last change.
2021-06-06 12:44:49 +03:00
Fabrice Nicol
5a8a5a990a Add support for Mercury (https://mercurylang.org) in 'etags'
Tag declarations starting lines with ':-'.
By default, all declarations are tagged.  Optionally, first
predicate or functions in clauses can be tagged as in Prolog
support using '--declarations'.  (Bug#47408).
* lib-src/etags.c (test_objc_is_mercury, Mercury_functions)
(mercury_skip_comment,  mercury_decl, mercury_pr):
Implement Mercury support.  As Mercury and Objective-C have
the same file extension .m, a heuristic test tries to detect
the language.

* doc/man/etags.1: Document the change.  Add Mercury-specific
 behavior for '--declarations'.  This option tags first
predicates or functions in clauses in addition to declarations.
2021-06-06 12:29:29 +03:00
Eli Zaretskii
ae3ec0860a Improve documentation of 'etags' tests
* test/manual/etags/README: New file.  (Bug#46055)

* test/README: Mention separate README files for tests in the
'manual' subdirectory
2021-05-20 13:02:29 +03:00
Eli Zaretskii
f572735c51 Fix the etags test suite
* test/manual/etags/ETAGS.good_2:
* test/manual/etags/ETAGS.good_3:
* test/manual/etags/ETAGS.good_4:
* test/manual/etags/ETAGS.good_5:
* test/manual/etags/ETAGS.good_6:
* test/manual/etags/CTAGS.good: Adjust to addition test.rs.
2021-05-17 19:39:45 +03:00
Lars Ingebrigtsen
e72dfe9669 Add an etags test for Rust (bug#46055) 2021-05-17 18:25:08 +02:00
Eli Zaretskii
2becaf8624 Update the etags/ctags test files
* test/manual/etags/ETAGS.good_1:
* test/manual/etags/ETAGS.good_2:
* test/manual/etags/ETAGS.good_3:
* test/manual/etags/ETAGS.good_4:
* test/manual/etags/ETAGS.good_5:
* test/manual/etags/ETAGS.good_6:
* test/manual/etags/CTAGS.good: Adjust to current codebase.
2021-05-17 19:06:56 +03:00
Stefan Kangas
0a4dc70830 ; Normalize and add missing first and last lines 2021-04-19 12:21:01 +02:00
Stefan Kangas
289ec2d911 ; Remove some useless comments 2021-04-16 14:54:02 +02:00
Stefan Monnier
cf774fb8cc * lisp/files.el (file-modes-number-to-symbolic): Add filetype arg.
* lisp/tar-mode.el (tar-header-block-summarize): Use it.
(tar-grind-file-mode): Declare obsolete.
2021-04-12 12:46:47 -04:00
Stefan Monnier
b815445cea Fix copyright lines mistakenly treated as outline headers
* lisp/emacs-lisp/generator.el:
* test/lisp/cedet/semantic-utest.el:
* test/lisp/cedet/semantic/format-tests.el:
* test/lisp/cedet/semantic/fw-tests.el:
* test/lisp/cedet/semantic/bovine/gcc-tests.el:
* test/lisp/cedet/semantic/format-resources/test-fmt.el:
* test/manual/cedet/semantic-tests.el:
* lisp/obsolete/inversion.el: Use only 2 semi-colons before "Copyright".
2021-03-18 23:32:57 -04:00