示例#1
0
 def test_parse_date_date_no_separation(self):
     self.assertEqual(sgfrename.parse_date('20190101'), '2019-01-01')
示例#2
0
 def test_parse_date_hyphens_not_escaped(self):
     self.assertEqual(sgfrename.parse_date('20190101 [12\:07\]'),
                      '2019-01-01 12-07')
示例#3
0
 def test_parse_date_date_empty(self):
     self.assertEqual(sgfrename.parse_date(''), '')
示例#4
0
 def test_parse_date_hyphens_not_padded(self):
     self.assertEqual(sgfrename.parse_date('2019 -   1   -1 '),
                      '2019-01-01')