Implemented testInsert function