Esempio n. 1
0
def test_error_view(patch, pyramid_request):
    handle_exception = patch("h.views.errors.handle_exception")
    exception = Mock()

    result = error(exception, pyramid_request)

    handle_exception.assert_called_once_with(pyramid_request, exception)
    assert result == {}
Esempio n. 2
0
def test_error_view(patch, pyramid_request):
    handle_exception = patch("h.views.errors.handle_exception")
    exception = Mock()

    result = error(exception, pyramid_request)

    handle_exception.assert_called_once_with(pyramid_request, exception)
    assert result == {}