Add tests for patchLeadHandler