Fixed mem leak, added 4th test