unit test tools.scaffold, fix a bug in scaffolding docs
parent
9a7131d000
commit
cd0986509c
|
@ -0,0 +1,21 @@
|
||||||
|
! Copyright (C) 2009 Doug Coleman.
|
||||||
|
! See http://factorcode.org/license.txt for BSD license.
|
||||||
|
USING: tools.test tools.scaffold unicode.case kernel
|
||||||
|
multiline tools.scaffold.private io.streams.string ;
|
||||||
|
IN: tools.scaffold.tests
|
||||||
|
|
||||||
|
: undocumented-word ( obj1 obj2 -- obj3 obj4 )
|
||||||
|
[ >lower ] [ >upper ] bi* ;
|
||||||
|
|
||||||
|
[
|
||||||
|
<" HELP: undocumented-word
|
||||||
|
{ $values
|
||||||
|
{ "obj1" object } { "obj2" object }
|
||||||
|
{ "obj3" object } { "obj4" object }
|
||||||
|
}
|
||||||
|
{ $description "" } ;
|
||||||
|
">
|
||||||
|
]
|
||||||
|
[
|
||||||
|
[ \ undocumented-word (help.) ] with-string-writer
|
||||||
|
] unit-test
|
|
@ -134,7 +134,7 @@ ERROR: no-vocab vocab ;
|
||||||
vocabulary>> using get [ conjoin ] [ drop ] if* ;
|
vocabulary>> using get [ conjoin ] [ drop ] if* ;
|
||||||
|
|
||||||
: ($values.) ( array -- )
|
: ($values.) ( array -- )
|
||||||
[
|
[ bl ] [
|
||||||
"{ " write
|
"{ " write
|
||||||
dup array? [ first ] when
|
dup array? [ first ] when
|
||||||
dup lookup-type [
|
dup lookup-type [
|
||||||
|
@ -145,7 +145,7 @@ ERROR: no-vocab vocab ;
|
||||||
null add-using
|
null add-using
|
||||||
] if
|
] if
|
||||||
" }" write
|
" }" write
|
||||||
] each ;
|
] interleave ;
|
||||||
|
|
||||||
: 4bl ( -- )
|
: 4bl ( -- )
|
||||||
" " write ; inline
|
" " write ; inline
|
||||||
|
|
Loading…
Reference in New Issue