Skip to content

Commit 45d2b8e

Browse files
committed
Added documenting comments
1 parent 575b2e8 commit 45d2b8e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pandas/util/testing.py

+2
Original file line numberDiff line numberDiff line change
@@ -994,6 +994,7 @@ def raise_assert_detail(obj, message, left, right, diff=None):
994994
left = repr(left)
995995

996996
if PY2 and isinstance(left, string_types):
997+
# left needs to be printable in native text type in python2
997998
left = left.encode('utf-8')
998999

9991000
if isinstance(right, np.ndarray):
@@ -1002,6 +1003,7 @@ def raise_assert_detail(obj, message, left, right, diff=None):
10021003
right = repr(right)
10031004

10041005
if PY2 and isinstance(right, string_types):
1006+
# right needs to be printable in native text type in python2
10051007
right = right.encode('utf-8')
10061008

10071009
msg = """{obj} are different

0 commit comments

Comments
 (0)