コード例 #1
0
ファイル: tests.py プロジェクト: WilliamRen/raven-django
    def test_does_exclude_filtered_types(self, get_option, exc_info, captureException):
        exc_info.return_value = self.exc_info
        get_option.return_value = ['ValueError']

        sentry_exception_handler(request=self.request)

        assert not captureException.called
コード例 #2
0
ファイル: tests.py プロジェクト: nikolas/raven-django
    def test_does_exclude_filtered_types(self, get_option, exc_info,
                                         captureException):
        exc_info.return_value = self.exc_info
        get_option.return_value = ['ValueError']

        sentry_exception_handler(request=self.request)

        assert not captureException.called
コード例 #3
0
ファイル: tests.py プロジェクト: WilliamRen/raven-django
    def test_ignore_exceptions_with_module_match(self, get_option, exc_info, captureException):
        exc_info.return_value = self.exc_info
        get_option.return_value = ['builtins.ValueError']
        if not six.PY3:
            get_option.return_value = ['exceptions.ValueError']

        sentry_exception_handler(request=self.request)

        assert not captureException.called
コード例 #4
0
ファイル: tests.py プロジェクト: nikolas/raven-django
    def test_ignore_exceptions_with_module_match(self, get_option, exc_info,
                                                 captureException):
        exc_info.return_value = self.exc_info
        get_option.return_value = ['builtins.ValueError']
        if not six.PY3:
            get_option.return_value = ['exceptions.ValueError']

        sentry_exception_handler(request=self.request)

        assert not captureException.called
コード例 #5
0
ファイル: tests.py プロジェクト: nikolas/raven-django
    def test_does_capture_exception(self, exc_info, captureException):
        exc_info.return_value = self.exc_info
        sentry_exception_handler(request=self.request)

        captureException.assert_called_once_with(exc_info=self.exc_info,
                                                 request=self.request)
コード例 #6
0
ファイル: tests.py プロジェクト: WilliamRen/raven-django
    def test_does_capture_exception(self, exc_info, captureException):
        exc_info.return_value = self.exc_info
        sentry_exception_handler(request=self.request)

        captureException.assert_called_once_with(exc_info=self.exc_info, request=self.request)