Skip to content

Commit 26ee43e

Browse files
ksheddenjreback
authored andcommitted
Align options in chunk and full file read
1 parent b381327 commit 26ee43e

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

pandas/io/tests/test_stata.py

+6-3
Original file line numberDiff line numberDiff line change
@@ -914,7 +914,8 @@ def test_read_chunks_117(self):
914914
warnings.simplefilter("always")
915915
parsed = read_stata(fname, convert_categoricals=convert_categoricals,
916916
convert_dates=convert_dates)
917-
itr = read_stata(fname, iterator=True)
917+
itr = read_stata(fname, iterator=True, convert_categoricals=convert_categoricals,
918+
convert_dates=convert_dates)
918919

919920
pos = 0
920921
for j in range(5):
@@ -967,13 +968,15 @@ def test_read_chunks_115(self):
967968
for convert_categoricals in False, True:
968969
for convert_dates in False, True:
969970

971+
# Read the whole file
970972
with warnings.catch_warnings(record=True) as w:
971973
warnings.simplefilter("always")
972974
parsed = read_stata(fname, convert_categoricals=convert_categoricals,
973975
convert_dates=convert_dates)
974-
itr = read_stata(fname, iterator=True,
975-
convert_categoricals=convert_categoricals)
976976

977+
# Compare to what we get when reading by chunk
978+
itr = read_stata(fname, iterator=True, convert_dates=convert_dates,
979+
convert_categoricals=convert_categoricals)
977980
pos = 0
978981
for j in range(5):
979982
with warnings.catch_warnings(record=True) as w:

0 commit comments

Comments
 (0)