From 5c5e6b177691dbe5a138ad2752ed4c6d0e209610 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Mar 05 2015 11:57:30 +0000 Subject: Ignore SQLAlchemy error in the test coverage as we cannot test them --- diff --git a/progit/ui/repo.py b/progit/ui/repo.py index 8f31351..6f27290 100644 --- a/progit/ui/repo.py +++ b/progit/ui/repo.py @@ -779,7 +779,7 @@ def remove_user(repo, userid, username=None): SESSION.commit() progit.generate_gitolite_acls() flask.flash('User removed') - except SQLAlchemyError as err: + except SQLAlchemyError as err: # pragma: no cover SESSION.rollback() APP.logger.exception(err) flask.flash('User could not be removed', 'error') @@ -821,7 +821,7 @@ def add_user(repo, username=None): except progit.exceptions.ProgitException as msg: SESSION.rollback() flask.flash(msg, 'error') - except SQLAlchemyError as err: + except SQLAlchemyError as err: # pragma: no cover SESSION.rollback() APP.logger.exception(err) flask.flash('User could not be added', 'error')