From: Yuan Fu <casouri@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 63481-done@debbugs.gnu.org
Subject: bug#63481: 29.0.90; src/treesit-tests fail in treesit-basic-parsing
Date: Thu, 18 May 2023 14:46:53 -0700 [thread overview]
Message-ID: <D1FB5095-7005-4804-942A-DD6C8A7B7978@gmail.com> (raw)
In-Reply-To: <83zg61vq7e.fsf@gnu.org>
> On May 18, 2023, at 4:23 AM, Eli Zaretskii <eliz@gnu.org> wrote:
>
> Ping!
>
>> Date: Sat, 13 May 2023 09:40:28 +0300
>> From: Eli Zaretskii <eliz@gnu.org>
>>
>> To reproduce:
>>
>> $ cd test
>> $ make src/treesit-tests SELECTOR='treesit-basic-parsing'
>>
>> This results in:
>>
>> GEN src/treesit-tests.log
>> make[1]: Entering directory `/d/gnu/git/emacs/branch/test'
>> Running 1 tests (2023-05-13 09:36:51+0300, selector `treesit-basic-parsing')
>> Test treesit-basic-parsing backtrace:
>> signal(ert-test-failed (((should (equal (treesit-node-string (treesi
>> ert-fail(((should (equal (treesit-node-string (treesit-parser-root-n
>> (if (unwind-protect (setq value-12 (apply fn-10 args-11)) (setq form
>> (let (form-description-14) (if (unwind-protect (setq value-12 (apply
>> (let ((value-12 'ert-form-evaluation-aborted-13)) (let (form-descrip
>> (let* ((fn-10 #'equal) (args-11 (condition-case err (let ((signal-ho
>> (let ((parser (treesit-parser-create 'json))) (let* ((fn-5 #'eq) (ar
>> (progn (let ((parser (treesit-parser-create 'json))) (let* ((fn-5 #'
>> (unwind-protect (progn (let ((parser (treesit-parser-create 'json)))
>> (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn
>> (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current
>> (closure (t) nil (let* ((fn-0 #'treesit-language-available-p) (args-
>> ert--run-test-internal(#s(ert--test-execution-info :test #s(ert-test
>> ert-run-test(#s(ert-test :name treesit-basic-parsing :documentation
>> ert-run-or-rerun-test(#s(ert--stats :selector treesit-basic-parsing
>> ert-run-tests(treesit-basic-parsing #f(compiled-function (event-type
>> ert-run-tests-batch(treesit-basic-parsing)
>> ert-run-tests-batch-and-exit(treesit-basic-parsing)
>> eval((ert-run-tests-batch-and-exit 'treesit-basic-parsing) t)
>> command-line-1(("-L" ";." "-l" "ert" "-l" "src/treesit-tests.el" "--
>> command-line()
>> normal-top-level()
>> Test treesit-basic-parsing condition:
>> (ert-test-failed
>> ((should
>> (equal
>> (treesit-node-string ...)
>> "(ERROR)"))
>> :form
>> (equal "(document)" "(ERROR)")
>> :value nil :explanation
>> (arrays-of-different-length 10 7 "(document)" "(ERROR)" first-mismatch-at 1)))
>> FAILED 1/1 treesit-basic-parsing (0.000000 sec) at src/treesit-tests.el:59
>>
>> Ran 1 tests, 0 results as expected, 1 unexpected (2023-05-13 09:36:52+0300, 1.078125 sec)
>>
>> It looks to me that the test assumes an empty buffer should parse as
>> an error, but the latest JSON grammar succeeds to parse it as a valid
>> document.
>>
>> The rest of treesit-tests pass as expected.
>>
>> Can this be fixed, please?
I pushed the fix. This is indeed due to a change to tree-sitter-json, I linked to the commit in the message.
Yuan
next prev parent reply other threads:[~2023-05-18 21:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-13 6:40 bug#63481: 29.0.90; src/treesit-tests fail in treesit-basic-parsing Eli Zaretskii
2023-05-18 11:23 ` Eli Zaretskii
2023-05-18 21:46 ` Yuan Fu [this message]
2023-05-19 5:40 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=D1FB5095-7005-4804-942A-DD6C8A7B7978@gmail.com \
--to=casouri@gmail.com \
--cc=63481-done@debbugs.gnu.org \
--cc=eliz@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).