Added tests to ensure exceptions are propagated