#3390: replace a remaining has_key().
This commit is contained in:
parent
74bbc79d10
commit
56af5fcab7
|
@ -160,7 +160,7 @@ class TestResult:
|
||||||
return ''.join(traceback.format_exception(exctype, value, tb))
|
return ''.join(traceback.format_exception(exctype, value, tb))
|
||||||
|
|
||||||
def _is_relevant_tb_level(self, tb):
|
def _is_relevant_tb_level(self, tb):
|
||||||
return tb.tb_frame.f_globals.has_key('__unittest')
|
return '__unittest' in tb.tb_frame.f_globals
|
||||||
|
|
||||||
def _count_relevant_tb_levels(self, tb):
|
def _count_relevant_tb_levels(self, tb):
|
||||||
length = 0
|
length = 0
|
||||||
|
|
Loading…
Reference in New Issue