Rewrite testFormatTimePeriod() with a data provider