set up proper subnamespace for exceptions
added unit tests