summaryrefslogtreecommitdiff
path: root/test/lisp
Commit message (Collapse)AuthorAgeFilesLines
* ; Fix more typosStefan Kangas2020-10-032-3/+3
|
* Calc: fix formatting and parsing Unix time (bug#43759)Mattias Engdegård2020-10-021-0/+40
| | | | | | | | | | | | | The number of days from epoch to Jan 1, 1970 that was used in parsing and formatting Unix time was incorrect. The previous fix (in e368697ce36) was incomplete. Reported by Vincent Belaïche. * lisp/calc/calc-forms.el (math-unix-epoch): New constant. (math-format-date-part, math-parse-standard-date, calcFunc-unixtime): Use math-unix-epoch instead of a constant that is sometimes wrong. * test/lisp/calc/calc-tests.el (calc-unix-date): New test.
* Merge from origin/emacs-27Glenn Morris2020-10-025-7/+8
|\ | | | | | | | | | | | | | | | | 78eacf31e8 ; Fix many typos in symbols in docs and comments d5d12707d6 * doc/misc/flymake.texi (Using Flymake): Fix a typo. (Bug... # Conflicts: # lisp/allout.el # lisp/progmodes/ebrowse.el
| * ; Fix many typos in symbols in docs and commentsStefan Kangas2020-10-025-7/+8
| |
| * 2020-03-29 Michael R. Mauger <michael@mauger.com>Michael R. Mauger2020-10-011-1/+7
| | | | | | | | | | | | | | | | * lisp/progmodes/sql.el (sql-add-product): Re-correct argument spec. Previous change was due to my mistake; I have resolved back to the prior behavior (Bug#39960). * test/lisp/progmodes/sql-tests.el (sql-test-add-product): Added test to insure I don't make the same mistake again.
* | Calc: fix business days calculation (bug43677)Mattias Engdegård2020-10-021-0/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The calculation of business days was broken in 2012 (probably 310e60d9454fe2 or thereabouts) when the date representation changed epoch so that Jan 1, 1 AD became day number 1 instead of 0. Repair this, along with an unrelated bug that prevented arbitrary holiday weekdays from working. Reported by Aaron Zeng. * lisp/calc/calc-forms.el (math-to-business-day) (math-from-business-day): Correct calculation of weekdays using Calc's current (Rata Die) chronology. Modify loop condition to cope with odd sets of holiday weekdays. * test/lisp/calc/calc-tests.el (calc-business-days): New test.
* | Stop using a dynamically bound 'generated-autoload-file' variableLars Ingebrigtsen2020-10-021-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * doc/lispref/loading.texi (Autoload): Document change of name (bug#39823). * lisp/emacs-lisp/autoload.el (autoload-find-generated-file): Pass the file name in. (autoload-generated-file): Ditto. (autoload-file-load-name): Ditto. (generate-file-autoloads): Ditto. (autoload--setup-output): Ditto. (autoload-generate-file-autoloads): Ditto, and alter doc string to reflect when `generated-autoload-file' is heeded. (update-file-autoloads): Pass outfile in to functions. (autoload-find-destination): Ditto. (update-directory-autoloads): Make into an obsolete shim around `make-directory-autoloads'. (make-directory-autoloads): Renamed from `update-directory-autoloads' with new semantics. (batch-update-autoloads): Adjust caller. * lisp/emacs-lisp/package.el (package-generate-autoloads): Adjust caller.
* | Fix bug in wdired-get-filenameTino Calancha2020-10-011-0/+16
| | | | | | | | | | | | * lisp/wdired.el (wdired-get-filename): Acknowledge the first argument (bug#39280). * test/lisp/wdired-tests.el (wdired-test-bug39280): Add test.
* | Silence byte-compiler in two testsStefan Kangas2020-10-012-2/+3
| | | | | | | | | | | | * test/lisp/obsolete/cl-tests.el (require): * test/lisp/simple-tests.el (simple-test-count-words-bug-41761): Silence byte-compiler.
* | Remove mml-sec-test that assumes the first signatureLars Ingebrigtsen2020-10-011-31/+0
| | | | | | | | | | This is no longer supported; the user is asked for what signature to use.
* | Make gnus-base64-repad a bit stricter againAlex Bochannek2020-10-011-5/+8
| | | | | | | | | | * lisp/gnus/gnus-util.el (gnus-base64-repad): Make the code a bit stricter again.
* | Query for the signer when sending signed mail (with unknown signer)Robert Pluim2020-10-011-1/+0
| | | | | | | | | | | | | | | | | | * lisp/gnus/mml-sec.el (mml-secure-sender-sign-query): New function (bug#40118). (mml-secure-epg-sign): Use it to determine the signer (bug#40118). * lisp/gnus/mml-sec.el (mml-secure-allow-signing-with-unknown-recipient): Remove.
* | Stricter checks for D-Bus compound types.Michael Albinus2020-09-301-25/+29
| | | | | | | | | | | | | | | | * src/dbusbind.c (XD_DBUS_TYPE_P, Fdbus__init_bus) (xd_read_queued_messages): Use Fkeywordp instead of SYMBOLP. (xd_signature): Stricter checks for compound types. * test/lisp/net/dbus-tests.el (dbus-test01-compound-types): Extend test.
* | Minor code cleanup in dbus-tests.elMichael Albinus2020-09-301-33/+30
| | | | | | | | | | | | | | | | | | | | * test/lisp/net/dbus-tests.el (dbus--tests-dir): Make it a defconst. (dbus--test-method-reentry-handler): Mark args as unused. (dbus-test04-method-reentry): Tag it :expensive-test. Fix typo. (dbus-test06-property-types): Remove duplicate test. (dbus--test-introspect): Use `insert-file-contents-literally'. (dbus--test-validate-property): Mark expected-annotations as unused. (dbus--test-validate-m-or-s): Remove superfluous le-clause.
* | Add D-Bus method-call reentrant testHugh Daschbach2020-09-301-0/+34
| | | | | | | | | | | | * test/lisp/net/dbus-tests.el (dbus--tests-method-reentry-handler): New defun. (dbus-test04-method-reentry): New test. (Bug#43251)
* | * test/lisp/net/dbus-tests.el: Add timeout tests.Hugh Daschbach2020-09-301-0/+38
| | | | | | | | | | (dbus-test04-call-method-timeout, dbus-test07-introspection-timeout): New tests.
* | Add D-Bus introspection testsHugh Daschbach2020-09-302-0/+344
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/net/dbus.el (dbus-annotation-deprecated): New defconst. * test/lisp/net/dbus-tests.el (dbus--tests-dir): New defvar. (dbus--test-introspect, dbus--test-validate-interface) (dbus--test-validate-annotations, dbus--test-validate-property) (dbus--test-validate-m-or-s, dbus--test-validate-signal) (dbus--test-validate-method): New defuns. (dbus-test07-introspection): New test. * test/lisp/net/dbus-resources/org.gnu.Emacs.TestDBus.xml: New test data.
* | * test/lisp/net/dbus-tests.el: Add property tests. (Bug#43252)Hugh Daschbach2020-09-301-0/+396
| | | | | | | | | | | | (dbus--test-run-property-test, dbus--test-property): New defuns. (dbus-test06-property-types): New test for property registration, set, get.
* | Fix gnus-base64-repad test failuresLars Ingebrigtsen2020-09-301-6/+3
| |
* | More strict D-Bus type checkingMichael Albinus2020-09-291-11/+62
| | | | | | | | | | | | | | | | | | | | * lisp/net/dbus.el (dbus-register-monitor): Register proper key. (dbus-monitor-handler): Adapt docstring. Use grave text-quoting-style. * src/dbusbind.c (xd_signature, xd_append_arg): More strict tests. (syms_of_dbusbind): Adapt docstring. * test/lisp/net/dbus-tests.el (dbus-test01-basic-types): Extend test.
* | Repad the Face header in GnusAlex Bochannek2020-09-281-0/+98
| | | | | | | | | | | | * lisp/gnus/gnus-fun.el (gnus-convert-face-to-png): Use it. * lisp/gnus/gnus-util.el (gnus-base64-repad): New function (bug#43441).
* | Fix Gnus parsing of weekly recurring icalendar eventsJan Tatarik2020-09-281-51/+74
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/gnus/gnus-icalendar.el (gnus-icalendar-event:recurring-interval): Fix parsing of weekly recurring events (bug#43669). Example: in the absence of explicit INTERVAL value in the calendar event, a weekly event with occurrences scheduled for Mondays and Wednesdays should receive the default recurring interval of "1" and the org mode timestamp repeater should be "+1w". Due to a bug in the current code we receive "WEEKLY" and "+WEEKLYw" instead. The patch fixes the issue.
* | Document D-Bus monitoringMichael Albinus2020-09-271-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * doc/misc/dbus.texi: Replace "symbol" by "keyword" where appropriate. (Alternative Buses): Adapt dbus-init-bus description. (Errors and Events): Adapt dbus-event structure. New defuns dbus-event-destination-name, dbus-event-handler and dbus-event-arguments. (Monitoring Events): New node. * lisp/net/dbus.el: Replace "symbol" by "keyword" where appropriate. (cl-lib): Require. (dbus-register-monitor): Adapt the argument list. (dbus-monitor-handler): Extend. (dbus-init-bus): Adapt docstring. * test/lisp/net/dbus-tests.el (dbus-test01-compound-types): Skip if needed. Extend test.
* | ; * test/lisp/subr-tests.el (string-replace): Add more test casesMattias Engdegård2020-09-271-0/+13
| |
* | Add tiny optimization for string-searchLars Ingebrigtsen2020-09-271-0/+3
| | | | | | | | | | * src/fns.c (Fstring_search): Add tiny optimization for needles that are longer than the haystack (bug#43598).
* | Rename replace-in-string to string-replaceLars Ingebrigtsen2020-09-271-13/+13
| | | | | | | | | | | | | | | | | | * doc/lispref/searching.texi (Search and Replace): Update. * lisp/bindings.el (mode-line-position): Update callers. * lisp/subr.el (string-replace): Rename from replace-in-string since that clashes with XEmacs' replace-in-string which is equivalent to the Emacs replace-regexp-in-string (bug#43598).
* | Silence some byte-compiler warningsStefan Kangas2020-09-263-1/+6
| | | | | | | | | | | | | | | | | | * test/lisp/arc-mode-tests.el (arc-mode-test-archive-int-to-mode): * test/lisp/custom-tests.el (cus-test-opts): * test/lisp/help-fns-tests.el (foo-test-map) (help-fns-test--describe-keymap-foo): * test/src/fns-tests.el (w32-collate-ignore-punctuation) (fns-tests-func-arity): Silence byte-compiler warnings.
* | Repurpose libxml test for obsolete argumentStefan Kangas2020-09-261-0/+21
| | | | | | | | | | | | | | | | | | | | | | * test/src/xml-tests.el (libxml-tests): Move half this test for the recently obsoleted fourth argument to libxml-parse-xml-region... * test/lisp/xml-tests.el (xml-tests--remove-comments): ...to a new test here for xml-remove-comments. * test/src/xml-tests.el (libxml-tests--data-comments-discarded): Move test data from here... * test/lisp/xml-tests.el (xml-tests--data-with-comments): ...to here.
* | Fix out-of-tree make checkGlenn Morris2020-09-251-1/+5
| | | | | | | | | | * test/lisp/custom-tests.el (custom-test-admin-cus-test): New const. (check-for-wrong-custom-types): Use it.
* | Add an expensive test for defcustom typesLars Ingebrigtsen2020-09-251-0/+5
| | | | | | | | | | | | | | * admin/cus-test.el (cus-test-opts): Return the tests. * test/lisp/custom-tests.el (check-for-wrong-custom-types): Test custom types (bug#30990).
* | Fix replace-in-string infloop with empty pattern string (bug#43598)Mattias Engdegård2020-09-251-1/+3
| | | | | | | | | | | | * lisp/subr.el (replace-in-string): Raise an error if FROMSTRING is empty. * test/lisp/subr-tests.el (replace-in-string): Add test case.
* | Fix previous replace-in-string rewriteLars Ingebrigtsen2020-09-251-2/+2
| | | | | | | | | | * lisp/subr.el (replace-in-string): Fix logic errors in previous patch.
* | Fix replace-in-string multibyteness problems with string-searchLars Ingebrigtsen2020-09-251-1/+9
| | | | | | | | | | * lisp/subr.el (replace-in-string): Simplify by using the new string-search function (bug#43598).
* | Update a failing lisp testGlenn Morris2020-09-241-1/+1
| | | | | | | | | | * test/lisp/emacs-lisp/lisp-tests.el (up-list-no-cross-string): Update for recent "Don't signal scan-error" change.
* | Add skip condition for some dbus testsGlenn Morris2020-09-241-11/+15
| | | | | | | | | | | | * test/lisp/net/dbus-tests.el (dbus-test01-type-conversion) (dbus-test01-basic-types): Add skip for hydra.nixos.org failures. ; Standardize license notice
* | Remove TODO to convert files to unit testsStefan Kangas2020-09-232-4/+0
| | | | | | | | | | | | | | * test/lisp/textmodes/css-mode-tests.el: * test/lisp/progmodes/ruby-mode-tests.el: Remove TODO to convert test files into unit tests. The files are still useful for debugging. Ref: https://lists.gnu.org/r/emacs-devel/2020-09/msg01906.html
* | Convert some completion.el tests to ERTStefan Kangas2020-09-231-0/+170
| | | | | | | | | | * test/lisp/completion-tests.el: New file. * lisp/completion.el: Move commented out tests to completion-tests.el.
* | Convert allout unit tests to ERTStefan Kangas2020-09-232-0/+235
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * test/lisp/allout-tests.el: New file. * lisp/allout.el (allout-run-unit-tests-on-load) (allout-run-unit-tests): Remove. (allout-tests-obliterate-variable) (allout-tests-globally-unbound, allout-tests-globally-true) (allout-tests-locally-true, allout-test-resumptions): Move to allout-tests.el * test/lisp/allout-widgets-tests.el: New file. * lisp/allout-widgets.el (allout-widgets-run-unit-tests-on-load) (allout-widgets-run-unit-tests): Remove. (allout-test-range-overlaps): Move to allout-widgets-tests.el.
* | * test/lisp/net/dbus-tests.el (dbus-test01-basic-types): Adapt test.Michael Albinus2020-09-231-5/+6
| |
* | Allow the newline character in the character widget (Bug#15925)Mauro Aranda2020-09-231-0/+16
| | | | | | | | | | | | | | | | | | | | * lisp/wid-edit.el (widget-specify-field): Extend check for adding the boundary overlay. Plus, a minor comment indentation fix. (character widget): Tweak the valid-regexp to allow the newline character. * test/lisp/wid-edit-tests.el (widget-test-character-widget-value) (widget-test-editable-field-widget-value): New tests (bug#15925).
* | Make delete-pair only delete pairs that are part of insert-pair-alistmartin rudalics2020-09-221-2/+1
| | | | | | | | | | * lisp/emacs-lisp/lisp.el (delete-pair): Only delete pairs that are part of `insert-pair-alist' (bug#4136).
* | ; * test/lisp/progmodes/ps-mode-tests.el: Add missing backslashMattias Engdegård2020-09-221-1/+1
| |
* | Support shellcheck in compilation-modeStefan Kangas2020-09-221-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | * lisp/progmodes/compile.el (compilation-error-regexp-alist-alist): Add shellcheck regexp. * test/lisp/progmodes/compile-tests.el (compile-tests--test-regexps-data): (compile-test-error-regexps): Add test for shellcheck. * etc/compilation.txt: Add shellcheck example. * etc/NEWS: Announce the change. foo
* | Remove some unnecessary compat codeStefan Kangas2020-09-222-13/+9
| | | | | | | | | | | | | | * test/lisp/emacs-lisp/ert-x-tests.el (ert-test-describe-test): * test/lisp/wdired-tests.el (wdired-test-unfinished-edit-01): Remove unnecessary compat code; these tests should never need to run on older versions of Emacs.
* | Convert a manual test for nxml-mode to unit testStefan Kangas2020-09-211-0/+21
| | | | | | | | | | | | * test/manual/indent/nxml.xml: Delete file. * test/lisp/nxml/nxml-mode-tests.el (nxml-mode-test-comment-bug-17264): New test based on deleted file.
* | Convert manual indent test for ruby-mode into unit testStefan Kangas2020-09-212-0/+496
| | | | | | | | | | | | | | | | | | * test/manual/indent/ruby.rb: Move from here... * test/lisp/progmodes/ruby-mode-resources/ruby.rb: ...to here. * test/lisp/progmodes/ruby-mode-tests.el (ruby-mode-tests-data-dir): New variable. (ruby--indent/converted-from-manual-test): New test.
* | Convert manual indent test for scheme-mode into unit testStefan Kangas2020-09-211-0/+50
| | | | | | | | | | | | * test/manual/indent/scheme.scm: Delete file. * test/lisp/progmodes/scheme-tests.el: New file with unit test for scheme-mode based on deleted file.
* | Convert manual indent test for ps-mode into unit testStefan Kangas2020-09-211-0/+24
| | | | | | | | | | | | * test/manual/indent/ps-mode.ps: Delete file. * test/lisp/progmodes/ps-mode-tests.el (ps-mode-test-indent): New unit test based on deleted file.
* | Convert manual indent test for opascal-mode into unit testStefan Kangas2020-09-211-0/+45
| | | | | | | | | | | | * test/manual/indent/opascal.pas: Delete file. * test/lisp/progmodes/opascal-tests.el: New file with unit test for oposcal-mode based on deleted file.
* | Convert manual indent test for lisp-mode into unit testStefan Kangas2020-09-211-0/+12
| | | | | | | | | | | | * test/manual/indent/lisp.lisp: Delete file. * test/lisp/emacs-lisp/lisp-mode-tests.el (lisp-indent-defun): New unit test based on deleted file.