Skip to content
Snippets Groups Projects
Commit 086d1a66 authored by Piotr Maślanka's avatar Piotr Maślanka
Browse files

more coverage

parent a89f597b
No related branches found
No related tags found
No related merge requests found
import unittest
from satella.opentracing import trace_exception
from unittest import mock
class TestOpentracing(unittest.TestCase):
def test_trace_exception_none(self):
trace_exception(None)
trace_exception(5)
span = mock.Mock()
try:
raise ValueError()
except ValueError:
trace_exception(span)
span.set_tag.assert_called_with('error', True)
span.log_kv.assert_called()
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment