]> gitweb.factorcode.org Git - factor.git/commitdiff
Revert "tools.test: Print tests homoiconically. There is too much spacing still"
authorDoug Coleman <doug.coleman@gmail.com>
Mon, 24 Nov 2014 07:59:57 +0000 (23:59 -0800)
committerDoug Coleman <doug.coleman@gmail.com>
Mon, 24 Nov 2014 07:59:57 +0000 (23:59 -0800)
This reverts commit 34a197248c07a09c433ed11ebd92418e568016d3.

basis/tools/test/test.factor

index f93e6029a2fe0ff60642ef98f5bcb959a03db67f..b559bf3977d81835ed7e4429571ad25cade73303 100644 (file)
@@ -76,7 +76,8 @@ M: did-not-fail summary drop "Did not fail" ;
     [ { } quot with-datastack drop did-not-fail-literal t ] [ drop f f ] recover ;
 
 : experiment-title ( word -- string )
-    "(" ?head drop ")" ?tail drop search ;
+    "(" ?head drop ")" ?tail drop
+    H{ { CHAR: - CHAR: \s } } substitute >title ;
 
 MACRO: <experiment> ( word -- )
     [ stack-effect in>> length dup ]
@@ -84,14 +85,8 @@ MACRO: <experiment> ( word -- )
     '[ _ ndup _ narray _ prefix ] ;
 
 : experiment. ( seq -- )
-    [
-        [
-            rest verbose-tests? get
-            [ [ pprint* "" text ] each ]
-            [ [ [ pprint* "" text ] with-short-limits ] each ] if
-        ]
-        [ "" text first pprint-word flush ] bi
-    ] with-pprint nl ;
+    [ first write ": " write ]
+    [ rest verbose-tests? get [ . ] [ short. ] if flush ] bi ;
 
 :: experiment ( word: ( -- error ? ) line# -- )
     word <experiment> :> e