Add object lifetime tests