From 84815c61f1350c8037fa09d8493b824d0e6cfa1e Mon Sep 17 00:00:00 2001 From: Ratchet Date: Wed, 27 Mar 2024 11:52:43 +0200 Subject: [PATCH] py 311 adds additional newline at the end --- tests/test_basics.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/test_basics.py b/tests/test_basics.py index ff6a063..bfac634 100644 --- a/tests/test_basics.py +++ b/tests/test_basics.py @@ -223,7 +223,7 @@ def test_exception_mode(): assert str(e) == "my exception: 4", "wrong exception" assert isinstance(e, ValueError), "wrong exception type" assert type(e.__traceback__).__name__ == "traceback", "not a traceback" - assert traceback.format_tb(e.__traceback__)[-1].endswith('in task_exception\n raise ValueError(f"my exception: {i}")\n'), "wrong callastack" + assert 'in task_exception\n raise ValueError(f"my exception: {i}")\n' in traceback.format_tb(e.__traceback__)[-1], "wrong callstack" if __name__ == "__main__": test_task_order() \ No newline at end of file