MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_fromisoformat_ambiguous

Method test_fromisoformat_ambiguous

Lib/test/datetimetester.py:3367–3376  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

3365 self.assertEqual(dt, dt_rt)
3366
3367 def test_fromisoformat_ambiguous(self):
3368 # Test strings like 2018-01-31+12:15 (where +12:15 is not a time zone)
3369 separators = ['+', '-']
3370 for sep in separators:
3371 dt = self.theclass(2018, 1, 31, 12, 15)
3372 dtstr = dt.isoformat(sep=sep)
3373
3374 with self.subTest(dtstr=dtstr):
3375 dt_rt = self.theclass.fromisoformat(dtstr)
3376 self.assertEqual(dt, dt_rt)
3377
3378 def test_fromisoformat_timespecs(self):
3379 datetime_bases = [

Callers

nothing calls this directly

Calls 4

subTestMethod · 0.80
isoformatMethod · 0.45
fromisoformatMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected