diff options
| author | Eli Zaretskii | 2013-11-29 12:33:31 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2013-11-29 12:33:31 +0200 |
| commit | de20f087b85e60b0d5aa899141a3349d4d9da80d (patch) | |
| tree | 0a4ce082d12a09c91bcb8217ad826f2e5e324d57 /test | |
| parent | a48eb50b569677999fc2f8d6b59f0901f724ddb8 (diff) | |
| download | emacs-de20f087b85e60b0d5aa899141a3349d4d9da80d.tar.gz emacs-de20f087b85e60b0d5aa899141a3349d4d9da80d.zip | |
Fix reftex-tests on MS-Windows.
test/automated/reftex-tests.el (reftex-parse-from-file-test): Run
temp-dir through file-truename, to make sure the temporary file
names are comparable as strings.
Diffstat (limited to 'test')
| -rw-r--r-- | test/ChangeLog | 4 | ||||
| -rw-r--r-- | test/automated/reftex-tests.el | 9 |
2 files changed, 12 insertions, 1 deletions
diff --git a/test/ChangeLog b/test/ChangeLog index 3ed077a6808..e16e0b21281 100644 --- a/test/ChangeLog +++ b/test/ChangeLog | |||
| @@ -1,5 +1,9 @@ | |||
| 1 | 2013-11-29 Eli Zaretskii <eliz@gnu.org> | 1 | 2013-11-29 Eli Zaretskii <eliz@gnu.org> |
| 2 | 2 | ||
| 3 | * automated/reftex-tests.el (reftex-parse-from-file-test): Run | ||
| 4 | temp-dir through file-truename, to make sure the temporary file | ||
| 5 | names are comparable as strings. | ||
| 6 | |||
| 3 | * automated/decoder-tests.el (ert-test-decoder-prefer-utf-8): | 7 | * automated/decoder-tests.el (ert-test-decoder-prefer-utf-8): |
| 4 | Force Unix EOLs by using 'utf-8-unix', since the default of | 8 | Force Unix EOLs by using 'utf-8-unix', since the default of |
| 5 | 'utf-8' is system-dependent, while the test expects to see Unix | 9 | 'utf-8' is system-dependent, while the test expects to see Unix |
diff --git a/test/automated/reftex-tests.el b/test/automated/reftex-tests.el index de7f36d825a..74a9f3d806c 100644 --- a/test/automated/reftex-tests.el +++ b/test/automated/reftex-tests.el | |||
| @@ -95,7 +95,14 @@ | |||
| 95 | 95 | ||
| 96 | (ert-deftest reftex-parse-from-file-test () | 96 | (ert-deftest reftex-parse-from-file-test () |
| 97 | "Test `reftex-parse-from-file'." | 97 | "Test `reftex-parse-from-file'." |
| 98 | (let* ((temp-dir (make-temp-file "reftex-parse" 'dir)) | 98 | ;; Use file-truename to convert 8+3 aliases in $TEMP value on |
| 99 | ;; MS-Windows into their long file-name equivalents, which is | ||
| 100 | ;; necessary for the 'equal' and 'string=' comparisons below. This | ||
| 101 | ;; also resolves any symlinks, which cannot be bad for the same | ||
| 102 | ;; reason. (An alternatrive solution would be to use file-equal-p, | ||
| 103 | ;; but I'm too lazy to do that, as one of the tests compares a | ||
| 104 | ;; list.) | ||
| 105 | (let* ((temp-dir (file-truename (make-temp-file "reftex-parse" 'dir))) | ||
| 99 | (tex-file (expand-file-name "test.tex" temp-dir)) | 106 | (tex-file (expand-file-name "test.tex" temp-dir)) |
| 100 | (bib-file (expand-file-name "ref.bib" temp-dir))) | 107 | (bib-file (expand-file-name "ref.bib" temp-dir))) |
| 101 | (with-temp-buffer | 108 | (with-temp-buffer |