GNU bug report logs -
#36452
[PATCH] Add tests for bookmark.el
Previous Next
Reported by: Stefan Kangas <stefan <at> marxist.se>
Date: Sun, 30 Jun 2019 23:34:02 UTC
Severity: normal
Tags: patch
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #17 received at 36452 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Eli Zaretskii <eliz <at> gnu.org> writes:
> > > One particular aspect of the bookmarks that I'd like to see tested is
> > > non-ASCII bookmark names and annotations. The code includes some
> > > slightly involved logic for determining how to encode the info on
> > > disk, so I wonder how well does that work in practice.
> >
> > OK. I added tests for that in the attached patch using strings
> > manually copied from HELLO. It works just fine to save and then load
> > bookmarks for the set of languages I chose to include characters from.
> > That is, we have the same before bookmark-save as we get after
> > bookmark-load.
>
> Thanks. Please add to that text something that doesn't yield valid
> UTF-8 byte sequence. For example, these two strings:
>
> (decode-coding-string "\xE3\x32\x9A\x36" 'chinese-gb18030)
> (char-to-string (decode-char 'eight-bit #x81))
>
> (Please include these snippets directly, not their result as a literal
> string, to make sure the unusual characters survive intact.)
OK, added. The tests still pass (both interactively and in batch mode).
The first one, when I evaluate it, makes Emacs segfault. Not sure why
it works when I'm running the tests - I'd guess because Emacs is not
trying to display it? Let me know if you want a backtrace for this
crash and/or a separate bug report.
In any case, I've attached an updated patch with the two above
snippets included in the save/load test. Not sure if we should keep
the first one around, but I added a warning not to evaluate it.
What do you think?
Thanks,
Stefan Kangas
[0001-Add-tests-for-bookmark.el-Bug-36452.patch (application/octet-stream, attachment)]
This bug report was last modified 5 years and 328 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.