[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: master 491531b: Avoid ert test failures

From: Noam Postavsky
Subject: RE: master 491531b: Avoid ert test failures
Date: Tue, 18 Apr 2017 22:35:56 -0400

>     Avoid ert test failures
>     * lisp/emacs-lisp/ert.el (ert--expand-should-1):
>     Avoid errors related to undefined byte-compile-macro-environment.
>     Somehow masked until very recently because loading seq (eg)
>     loads bytecomp.  http://hydra.nixos.org/build/51730765
> ---

>  (defun ert--expand-should-1 (whole form inner-expander)
>    "Helper function for the `should' macro and its variants."
> +  (require 'bytecomp)                   ; FIXME?
>    (let ((form
>           (macroexpand form (append byte-compile-macro-environment
>                                     (cond

I introduced this dependency in [1: 58e418d2ce].  I did notice the
error once locally, and then it didn't come up again; I'm not quite
understanding how the masking works.

Anyway, I was considering fixing this by using (bound-and-true-p
byte-compile-macro-environment) instead of loading `bytecomp', which
almost seems to work except that eval-tests--bugs-24912-and-24913
fails because `should-error' fails to catch the error from
byte-compile.  That can be fixed by adding (require 'bytecomp) in that
test, but maybe it's better just to leave the require in ert?

1: 2016-12-06 22:20:23 -0500 58e418d2ceb82501f03d9c3316fd0a46faf7f0eb
  Fix ert-tests when running compiled

reply via email to

[Prev in Thread] Current Thread [Next in Thread]