summaryrefslogtreecommitdiff
path: root/tests/utils.scm
diff options
context:
space:
mode:
Diffstat (limited to 'tests/utils.scm')
-rw-r--r--tests/utils.scm23
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/utils.scm b/tests/utils.scm
index e1700709070..648e91f242d 100644
--- a/tests/utils.scm
+++ b/tests/utils.scm
@@ -306,6 +306,29 @@ skip these tests."
306 '("i686-linux-gnu" "i686-pc-gnu" 306 '("i686-linux-gnu" "i686-pc-gnu"
307 "i686-w64-mingw32"))) 307 "i686-w64-mingw32")))
308 308
309(test-equal "target-x86-32?"
310 '(#f #f #f #t #t #t #t #f)
311 ;; These are (according to Wikipedia) two RISC architectures
312 ;; by Intel and presumably not compatible with the x86-32 series.
313 (map target-x86-32?
314 '("i860-gnu" "i960-gnu"
315 ;; This is a 16-bit architecture
316 "i286-gnu"
317 ;; These are part of the x86-32 series.
318 "i386-gnu" "i486-gnu" "i586-gnu" "i686-gnu"
319 ;; Maybe this one will exist some day, but not yet.
320 "i786-gnu")))
321
322(test-equal "target-x86-64?"
323 '(#t #f #f #f)
324 (map target-x86-64?
325 `("x86_64-linux-gnu" "i386-linux-gnu"
326 ;; Just because it includes "64" doesn't make it 64-bit.
327 "aarch64-linux-gnu"
328 ;; Note that (expt 2 109) in decimal notation starts with 64.
329 ;; However, it isn't 32-bit.
330 ,(format #f "x86_~a-linux-gnu" (expt 2 109)))))
331
309(test-end) 332(test-end)
310 333
311(false-if-exception (delete-file temp-file)) 334(false-if-exception (delete-file temp-file))