From 4ce962e92568e52624959d8abc83f609abc3605c Mon Sep 17 00:00:00 2001 From: Nikodemus Siivola Date: Sun, 29 Apr 2012 20:55:35 +0300 Subject: [PATCH] tune bug-981106 test based on the heap size Fixes lp#983807. --- tests/gc.impure.lisp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/tests/gc.impure.lisp b/tests/gc.impure.lisp index cb9e3e7..ef4313a 100644 --- a/tests/gc.impure.lisp +++ b/tests/gc.impure.lisp @@ -85,10 +85,11 @@ (assert (eq :ok (handler-case (dotimes (runs 100 :ok) - (let ((len (length - (with-output-to-string (string) - (dotimes (i 1000000) - (write-sequence "hi there!" string)))))) - (assert (eql len (* 1000000 (length "hi there!")))))) + (let* ((n (truncate (dynamic-space-size) 1200)) + (len (length + (with-output-to-string (string) + (dotimes (i n) + (write-sequence "hi there!" string)))))) + (assert (eql len (* n (length "hi there!")))))) (storage-condition () :oom)))))) -- 1.7.10.4