test for memory leak