Add tests for _insert_task errors

Add individual tests covering every exception that should happen within
_insert_tasks, BadTaskStateError, TransientError, TombstonedTaskError
and TaskAlreadyExistsError.