Finish cleaning up test runs by mocking sendmail and fixing the SqlAlchemy warning