factor/library/test/kernel.factor

21 lines
587 B
Factor
Raw Normal View History

IN: scratchpad
2005-12-14 20:29:32 -05:00
USING: kernel kernel-internals math memory namespaces sequences
2006-10-06 20:27:40 -04:00
test errors ;
[ 0 ] [ f size ] unit-test
2005-09-18 01:37:28 -04:00
[ t ] [ [ \ = \ = ] all-equal? ] unit-test
2005-12-12 20:53:55 -05:00
! (clone) primitive was missing GC check
[ ] [ 1000000 [ drop H{ } clone >n n> drop ] each ] unit-test
2005-12-14 20:29:32 -05:00
[ t ] [ cell integer? ] unit-test
[ t ] [ bootstrap-cell integer? ] unit-test
[ [ 3 ] ] [ 3 f curry ] unit-test
[ [ \ + ] ] [ \ + f curry ] unit-test
[ [ \ + = ] ] [ \ + [ = ] curry ] unit-test
2006-10-06 20:27:40 -04:00
! Make sure we report the correct error on stack underflow
[ { kernel-error 11 f f } ]
[ [ clear drop ] catch ] unit-test