factor/basis/tools/memory/memory-tests.factor

25 lines
735 B
Factor
Raw Normal View History

USING: arrays assocs kernel math memory namespaces parser sequences
tools.memory tools.memory.private tools.test tools.time vm ;
2008-03-01 17:00:45 -05:00
IN: tools.memory.tests
2007-09-20 18:09:08 -04:00
{ } [ room. ] unit-test
{ } [ heap-stats. ] unit-test
{ t } [ [ gc gc ] collect-gc-events array? ] unit-test
{ } [ gc-events. ] unit-test
{ } [ gc-stats. ] unit-test
{ } [ gc-summary. ] unit-test
{ } [ callback-room. ] unit-test
! Each gc-event must reclaim something. #659
{ f } [
[ "resource:basis/tools/memory/memory.factor" run-file ] time
gc-events get [ space-reclaimed 0 < ] any?
] unit-test
{ t t t } [
get-code-blocks code-block-stats nip
[ CODE-BLOCK-UNOPTIMIZED of 0 > ]
[ CODE-BLOCK-OPTIMIZED of 0 > ]
[ CODE-BLOCK-PIC of 0 > ] tri
] unit-test