unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Joost Kremers <joostkremers@fastmail.fm>
To: help-gnu-emacs@gnu.org
Subject: Compiled vs. interpreted ERT test
Date: Thu, 27 Feb 2020 23:19:03 +0100	[thread overview]
Message-ID: <87r1yfr7vs.fsf@fastmail.fm> (raw)

Hi list,

I learned about the package `with-simulated-input`[1] which 
provides a macro of the same name that's intended for writing 
automated tests for code that takes user input. When trying to 
apply this in some ERT test, I found that it works fine if the 
tests are interpreted (e.g., loaded with `eval-defun`), but not 
when the test is byte-compiled. Byte-compiled tests fail with the 
following error:

```
(wrong-type-argument listp
                         #[nil "\300\207"
                               [t]
                               1])
```

I opened an issue on the package's Github page but the maintainer 
says he doesn't know how to debug this.[2] So I'm coming here in 
the hopes someone has an idea or a suggestion how to debug this.

TIA

Joost



Footnotes: 
[1]  https://github.com/DarwinAwardWinner/with-simulated-input

[2] 
https://github.com/DarwinAwardWinner/with-simulated-input/issues/6

-- 
Joost Kremers
Life has its moments



             reply	other threads:[~2020-02-27 22:19 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-27 22:19 Joost Kremers [this message]
2020-02-28  1:48 ` Compiled vs. interpreted ERT test Noam Postavsky
2020-02-28  2:18 ` Stefan Monnier
2020-02-28  3:16   ` Stefan Monnier
2020-02-28  8:07     ` Joost Kremers

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=87r1yfr7vs.fsf@fastmail.fm \
    --to=joostkremers@fastmail.fm \
    --cc=help-gnu-emacs@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.
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).