Skip to content

Commit b094be0

Browse files
committed
Fix tests
1 parent 10e2740 commit b094be0

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

tests/test_frame.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22

33
import inspect
44

5-
from types import FrameType
6-
75
from crashtest.frame import Frame
86
from tests.helpers import nested_exception
97
from tests.helpers import simple_exception
@@ -19,15 +17,15 @@ def test_frame() -> None:
1917
same_frame = Frame(frame_info)
2018
assert frame_info.frame == frame.frame
2119

22-
assert frame.lineno == 11
20+
assert frame.lineno == 14
2321
assert frame.filename == __file__
2422
assert frame.function == "test_frame"
2523
assert frame.line == " simple_exception()\n"
2624

2725
with open(__file__) as f:
2826
assert f.read() == frame.file_content
2927

30-
assert repr(frame) == f"<Frame {__file__}, test_frame, 11>"
28+
assert repr(frame) == f"<Frame {__file__}, test_frame, 14>"
3129

3230
try:
3331
nested_exception()
@@ -44,7 +42,7 @@ def test_frame() -> None:
4442

4543
def test_frame_with_no_context_should_return_empty_line() -> None:
4644
frame = Frame(
47-
inspect.FrameInfo(FrameType(), "filename.py", 123, "function", None, 3)
45+
inspect.FrameInfo(None, "filename.py", 123, "function", None, 3) # type: ignore
4846
)
4947

5048
assert frame.line == ""

0 commit comments

Comments
 (0)