Email error handling

Using mock as a mock library instead of ludibrio and closes #71