@pytest.mark.parametrize('date_str,freq,expected', [('2013Q2', None, datetime(2013, 4, 1)), ('2013Q2', 'A-APR', datetime(2012, 8, 1)), ('2013-Q2', 'A-DEC', datetime(2013, 4, 1))])
def test_parsers_quarterly_with_freq(date_str, freq, expected):
    (result, _) = parsing.parse_time_string(date_str, freq=freq)
    assert (result == expected)
@pytest.mark.parametrize('date_str,freq,expected', [('2013Q2', None, datetime(2013, 4, 1)), ('2013Q2', 'A-APR', datetime(2012, 8, 1)), ('2013-Q2', 'A-DEC', datetime(2013, 4, 1))])
def test_parsers_quarterly_with_freq(date_str, freq, expected):
    (result, _) = parsing.parse_time_string(date_str, freq=freq)
    assert (result == expected)