84522b3 Use nose tools to check for exceptions

6 files Authored by pviktori 12 years ago, Committed by mkosek 12 years ago,
    Use nose tools to check for exceptions
    
    Some of our tests checked for exceptions using an error-prone
    try block: they allowed the expected exception to pass, but sometimes
    forgot an else block, so the test passed when an exception wasn't
    thrown.
    
    This changes the tests to use the appropriate nose tools (raises,
    assert_raises).
    For consistency, tests that had a correct else block are also changed.
    
    Also fix some test problems that were hidden by the above:
    - in some sudorule and HBAC tests, change the *_add_user argument name
      from `users` to `user`
    - don't remove HBAC testing data while it was still used