_pytest: address review feedback (thanks Bruno!)

This commit is contained in:
Michael Vogt 2024-06-03 08:52:38 +02:00
parent 6aca93bcd3
commit fa769e2612
2 changed files with 2 additions and 5 deletions

View File

@ -849,7 +849,7 @@ class FormattedExcinfo:
if self.truncate_args:
str_repr = saferepr(argvalue)
else:
str_repr = safeformat(argvalue)
str_repr = saferepr(argvalue, maxsize=None)
args.append((argname, str_repr))
return ReprFuncArgs(args)
return None

View File

@ -448,10 +448,7 @@ class Node(abc.ABC, metaclass=NodeMeta):
else:
truncate_locals = True
if self.config.getoption("verbose", 0) > 2:
truncate_args = False
else:
truncate_args = True
truncate_args = False if self.config.getoption("verbose", 0) > 2 else True
# excinfo.getrepr() formats paths relative to the CWD if `abspath` is False.
# It is possible for a fixture/test to change the CWD while this code runs, which