emacs-diffs
[Top][All Lists]
Advanced

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

feature/native-comp 28df049 2/2: * test/src/comp-tests.el (comp-tests-bo


From: Andrea Corallo
Subject: feature/native-comp 28df049 2/2: * test/src/comp-tests.el (comp-tests-bootstrap): Fix test.
Date: Thu, 14 May 2020 02:35:09 -0400 (EDT)

branch: feature/native-comp
commit 28df049b8d43586d5a91a7b3e1d9e05131572afc
Author: Andrea Corallo <address@hidden>
Commit: Andrea Corallo <address@hidden>

    * test/src/comp-tests.el (comp-tests-bootstrap): Fix test.
---
 test/src/comp-tests.el | 17 ++++++++---------
 1 file changed, 8 insertions(+), 9 deletions(-)

diff --git a/test/src/comp-tests.el b/test/src/comp-tests.el
index 4768e1a..ce98227 100644
--- a/test/src/comp-tests.el
+++ b/test/src/comp-tests.el
@@ -44,21 +44,20 @@ Check that the resulting binaries do not differ."
                            "../../lisp/emacs-lisp/comp.el"))
          (comp1-src (make-temp-file "stage1-" nil ".el"))
          (comp2-src (make-temp-file "stage2-" nil ".el"))
-         (comp1 (concat comp1-src "n"))
-         (comp2 (concat comp2-src "n"))
          ;; Can't use debug symbols.
          (comp-debug 0))
     (copy-file comp-src comp1-src t)
     (copy-file comp-src comp2-src t)
     (load (concat comp-src "c") nil nil t t)
-    (should (null (subr-native-elisp-p (symbol-function #'native-compile))))
+    (should-not (subr-native-elisp-p (symbol-function #'native-compile)))
     (message "Compiling stage1...")
-    (load (native-compile comp1-src) nil nil t t)
-    (should (subr-native-elisp-p (symbol-function 'native-compile)))
-    (message "Compiling stage2...")
-    (native-compile comp2-src)
-    (message "Comparing %s %s" comp1 comp2)
-    (should (= (call-process "cmp" nil nil nil comp1 comp2) 0))))
+    (let ((comp1-eln (native-compile comp1-src)))
+      (load comp1-eln nil nil t t)
+      (should (subr-native-elisp-p (symbol-function 'native-compile)))
+      (message "Compiling stage2...")
+      (let ((comp2-eln (native-compile comp2-src)))
+        (message "Comparing %s %s" comp1-eln comp2-eln)
+        (should (= (call-process "cmp" nil nil nil comp1-eln comp2-eln) 0))))))
 
 (ert-deftest comp-tests-provide ()
   "Testing top level provide."



reply via email to

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