Add coverage for previous keys test