Insure that the test for bug 881445 runs with a large enough dynamic space.
authorJoshua Elsasser <joshua@elsasser.org>
Wed, 23 Nov 2011 07:29:13 +0000 (23:29 -0800)
committerJoshua Elsasser <joshua@elsasser.org>
Wed, 23 Nov 2011 07:29:13 +0000 (23:29 -0800)
tests/interface.impure.lisp
tests/interface.test.sh [new file with mode: 0644]
tests/subr.sh

index 33f7886..ac4776a 100644 (file)
   (assert (equal "foo" (documentation 'bug-643958-test 'function)))
   (setf (documentation 'bug-643958-test 'function) "bar")
   (assert (equal "bar" (documentation 'bug-643958-test 'function))))
-
-(with-test (:name :bug-881445
-            :skipped-on '(not :x86-64))
-  (let ((x (make-array (1- (expt 2 32)) :element-type '(unsigned-byte 8))))
-    (assert (> (sb-kernel:dynamic-usage) (length x)))
-    ;; prevent compiler from getting too smart...
-    (eval x)
-    t))
 \f
 ;;;; success
diff --git a/tests/interface.test.sh b/tests/interface.test.sh
new file mode 100644 (file)
index 0000000..9cbaf23
--- /dev/null
@@ -0,0 +1,39 @@
+#!/bin/sh
+
+# tests for problems in the interface presented to the user/programmer
+
+# This software is part of the SBCL system. See the README file for
+# more information.
+#
+# While most of SBCL is derived from the CMU CL system, the test
+# files (like this one) were written from scratch after the fork
+# from CMU CL.
+#
+# This software is in the public domain and is provided with
+# absolutely no warranty. See the COPYING and CREDITS files for
+# more information.
+
+. ./subr.sh
+
+use_test_subdirectory
+
+tmpscript=$TEST_FILESTEM.lisp-script
+
+printenv
+
+# bug 881445
+case "$SBCL_MACHINE_TYPE" in
+    X86-64)
+        cat > $tmpscript <<EOF
+(let ((x (make-array (1- (expt 2 32)) :element-type '(unsigned-byte 8))))
+  (assert (> (sb-kernel:dynamic-usage) (length x)))
+  ;; prevent compiler from getting too smart...
+  (eval x)
+  (sb-ext:quit :unix-status $EXIT_LISP_WIN))
+EOF
+        run_sbcl_with_args --dynamic-space-size 5GB $SBCL_ARGS --load $tmpscript
+        check_status_maybe_lose "bug 881445" $?
+        ;;
+esac
+
+exit $EXIT_TEST_WIN
index b96dd29..84ee1a4 100644 (file)
@@ -66,6 +66,11 @@ run_sbcl () (
     fi
 )
 
+run_sbcl_with_args () (
+    set -u
+    "$SBCL_RUNTIME" --core "$SBCL_CORE" "$@"
+)
+
 run_sbcl_with_core () (
     set -u
     core="$1"