MCPcopy Create free account
hub / github.com/dateutil/dateutil / test_parse_yearfirst

Function test_parse_yearfirst

tests/test_parser.py:180–185  ·  view source on GitHub ↗
(sep)

Source from the content-addressed store, hash-verified

178
179@pytest.mark.parametrize('sep', ['-', '.', '/', ' '])
180def test_parse_yearfirst(sep):
181 expected = datetime(2010, 9, 3)
182 fmt = sep.join(['%Y', '%m', '%d'])
183 dstr = expected.strftime(fmt)
184 result = parse(dstr, yearfirst=True)
185 assert result == expected
186
187
188@pytest.mark.parametrize('dstr,expected', [

Callers

nothing calls this directly

Calls 1

parseFunction · 0.90

Tested by

no test coverage detected