| 352 | ### |
| 353 | # Test parse_isodate |
| 354 | def __make_date_examples(): |
| 355 | dates_no_day = [ |
| 356 | date(1999, 12, 1), |
| 357 | date(2016, 2, 1) |
| 358 | ] |
| 359 | |
| 360 | dates_no_day.append(date(1000, 11, 1)) |
| 361 | |
| 362 | # Only one supported format for dates with no day |
| 363 | o = zip(dates_no_day, it.repeat('%Y-%m')) |
| 364 | |
| 365 | dates_w_day = [ |
| 366 | date(1969, 12, 31), |
| 367 | date(1900, 1, 1), |
| 368 | date(2016, 2, 29), |
| 369 | date(2017, 11, 14) |
| 370 | ] |
| 371 | |
| 372 | dates_w_day_fmts = ('%Y%m%d', '%Y-%m-%d') |
| 373 | o = it.chain(o, it.product(dates_w_day, dates_w_day_fmts)) |
| 374 | |
| 375 | return list(o) |
| 376 | |
| 377 | |
| 378 | @pytest.mark.parametrize('d,dt_fmt', __make_date_examples()) |