[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Fix some failing tests in BSD systems
From: |
Daniel Martín |
Subject: |
Re: [PATCH] Fix some failing tests in BSD systems |
Date: |
Sun, 03 Jan 2021 22:08:56 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.1 (darwin) |
Eli Zaretskii <eliz@gnu.org> writes:
>> From: Daniel Martín <mardani29@yahoo.es>
>> Date: Sun, 03 Jan 2021 18:16:46 +0100
>>
>> (ert-deftest xref--xref-file-name-display-is-abs ()
>> - (let ((xref-file-name-display 'abs))
>> - (should (equal (delete-dups
>> - (mapcar 'xref-location-group
>> - (xref-tests--locations-in-data-dir
>> "\\(bar\\|foo\\)")))
>> - (list
>> - (concat xref-tests--data-dir "file1.txt")
>> - (concat xref-tests--data-dir "file2.txt"))))))
>> + (let ((xref-file-name-display 'abs)
>> + ;; BSD find may add an extra '/' to the path.
>> + (expected (list
>> + (concat xref-tests--data-dir "/?file1.txt")
>> + (concat xref-tests--data-dir "/?file2.txt")))
>
> Why are we producing file names by concatenation, instead of calling
> expand-file-name? Wouldn't using the latter solve the problem? Or
> what did I miss?
Yes. I've attached another solution in terms of expand-file-name and
file-relative-name.
0001-Fix-some-xref-tests-for-systems-with-BSD-find.patch
Description: Text Data
- [PATCH] Fix some failing tests in BSD systems, Daniel Martín, 2021/01/03
- Re: [PATCH] Fix some failing tests in BSD systems, Eli Zaretskii, 2021/01/03
- Re: [PATCH] Fix some failing tests in BSD systems,
Daniel Martín <=
- Re: [PATCH] Fix some failing tests in BSD systems, Dmitry Gutov, 2021/01/03
- Re: [PATCH] Fix some failing tests in BSD systems, Eli Zaretskii, 2021/01/03
- Re: [PATCH] Fix some failing tests in BSD systems, Dmitry Gutov, 2021/01/04
- Re: [PATCH] Fix some failing tests in BSD systems, Eli Zaretskii, 2021/01/04
- Re: [PATCH] Fix some failing tests in BSD systems, Dmitry Gutov, 2021/01/04
- Re: [PATCH] Fix some failing tests in BSD systems, Daniel Martín, 2021/01/04
- Re: [PATCH] Fix some failing tests in BSD systems, Dmitry Gutov, 2021/01/05
- Re: [PATCH] Fix some failing tests in BSD systems, Daniel Martín, 2021/01/06
- Re: [PATCH] Fix some failing tests in BSD systems, Dmitry Gutov, 2021/01/06
- Re: [PATCH] Fix some failing tests in BSD systems, Stefan Monnier, 2021/01/06