factor/basis/inspector/inspector-tests.factor

36 lines
653 B
Factor
Raw Normal View History

2007-09-20 18:09:08 -04:00
USING: kernel tools.test math namespaces prettyprint
sequences inspector io.streams.string ;
2008-03-01 17:00:45 -05:00
IN: inspector.tests
2007-09-20 18:09:08 -04:00
[ 1 2 3 ] describe
f describe
\ + describe
H{ } describe
H{ } describe
{ "fixnum\n\n" } [ [ 3 describe ] with-string-writer ] unit-test
2008-06-27 01:48:05 -04:00
{ } [ H{ } clone inspect ] unit-test
2008-06-27 01:48:05 -04:00
{ } [ "a" "b" &add ] unit-test
2008-06-27 01:48:05 -04:00
{ H{ { "b" "a" } } } [ me get ] unit-test
2008-06-27 01:48:05 -04:00
{ } [ "x" 0 &put ] unit-test
2008-06-27 01:48:05 -04:00
{ H{ { "b" "x" } } } [ me get ] unit-test
2008-06-27 01:48:05 -04:00
{ } [ 0 &at ] unit-test
2008-06-27 01:48:05 -04:00
{ "x" } [ me get ] unit-test
2008-06-27 01:48:05 -04:00
{ } [ &back ] unit-test
2008-06-27 01:48:05 -04:00
{ } [ "y" 0 &rename ] unit-test
2008-06-27 01:48:05 -04:00
{ H{ { "y" "x" } } } [ me get ] unit-test
2008-06-27 01:48:05 -04:00
{ } [ 0 &delete ] unit-test
2008-06-27 01:48:05 -04:00
{ H{ } } [ me get ] unit-test