FIxing a small memory leak issue in the test file