MCPcopy
hub / github.com/pandas-dev/pandas / test_split_regex

Function test_split_regex

pandas/tests/strings/test_split_partition.py:53–59  ·  view source on GitHub ↗
(any_string_dtype)

Source from the content-addressed store, hash-verified

51
52
53def test_split_regex(any_string_dtype):
54 # GH 43563
55 # explicit regex = True split
56 values = Series("xxxjpgzzz.jpg", dtype=any_string_dtype)
57 result = values.str.split(r"\.jpg", regex=True)
58 exp = Series([["xxxjpgzzz", ""]])
59 tm.assert_series_equal(result, exp)
60
61
62def test_split_regex_explicit(any_string_dtype):

Callers

nothing calls this directly

Calls 2

SeriesClass · 0.90
splitMethod · 0.80

Tested by

no test coverage detected