diff options
| author | Mark Oteiza | 2017-09-09 00:46:41 -0400 |
|---|---|---|
| committer | Mark Oteiza | 2017-09-09 00:46:41 -0400 |
| commit | be9bc8e67d6caf6d61fe4f46ac5b640ada16ba95 (patch) | |
| tree | 4042d8c5def741ddf3397925bfd213f2efba8495 /test | |
| parent | ce9640845155c1dd9c11e46104f223af7cd4f7fa (diff) | |
| download | emacs-be9bc8e67d6caf6d61fe4f46ac5b640ada16ba95.tar.gz emacs-be9bc8e67d6caf6d61fe4f46ac5b640ada16ba95.zip | |
; Fix previous commit
See https://lists.gnu.org/archive/html/emacs-devel/2017-09/msg00101.html
* test/lisp/xdg.el: Remove match data tests.
* lisp/xdg.el (xdg-user-dir): Fix docstring. Remove save-match-data.
(xdg-desktop-read-file, xdg-desktop-strings): Remove save-match-data.
Diffstat (limited to 'test')
| -rw-r--r-- | test/lisp/xdg-tests.el | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/test/lisp/xdg-tests.el b/test/lisp/xdg-tests.el index e7e122b54ee..59c850b07af 100644 --- a/test/lisp/xdg-tests.el +++ b/test/lisp/xdg-tests.el | |||
| @@ -3,7 +3,6 @@ | |||
| 3 | ;; Copyright (C) 2017 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2017 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Maintainer: emacs-devel@gnu.org | 5 | ;; Maintainer: emacs-devel@gnu.org |
| 6 | |||
| 7 | ;; Author: Mark Oteiza <mvoteiza@udel.edu> | 6 | ;; Author: Mark Oteiza <mvoteiza@udel.edu> |
| 8 | 7 | ||
| 9 | ;; This file is part of GNU Emacs. | 8 | ;; This file is part of GNU Emacs. |
| @@ -31,24 +30,6 @@ | |||
| 31 | (defconst xdg-tests-data-dir | 30 | (defconst xdg-tests-data-dir |
| 32 | (expand-file-name "test/data/xdg" source-directory)) | 31 | (expand-file-name "test/data/xdg" source-directory)) |
| 33 | 32 | ||
| 34 | (ert-deftest xdg-match-data () | ||
| 35 | "Ensure public functions do not mangle match data." | ||
| 36 | (let ((data '(1 9))) | ||
| 37 | (save-match-data | ||
| 38 | (set-match-data data) | ||
| 39 | (xdg-user-dir "DOCUMENTS") | ||
| 40 | (should (equal (match-data) data)))) | ||
| 41 | (let ((data '(2 9))) | ||
| 42 | (save-match-data | ||
| 43 | (set-match-data data) | ||
| 44 | (xdg-desktop-read-file (expand-file-name "test.desktop" xdg-tests-data-dir)) | ||
| 45 | (should (equal (match-data) data)))) | ||
| 46 | (let ((data '(3 9))) | ||
| 47 | (save-match-data | ||
| 48 | (set-match-data data) | ||
| 49 | (xdg-desktop-strings "a;b") | ||
| 50 | (should (equal (match-data) data))))) | ||
| 51 | |||
| 52 | (ert-deftest xdg-desktop-parsing () | 33 | (ert-deftest xdg-desktop-parsing () |
| 53 | "Test `xdg-desktop-read-file' parsing of .desktop files." | 34 | "Test `xdg-desktop-read-file' parsing of .desktop files." |
| 54 | (let ((tab (xdg-desktop-read-file | 35 | (let ((tab (xdg-desktop-read-file |