示例#1
0
def test_calendar_range():
    assert get_calendar_range(
        (None, datetime(2016, 2, 1, tzinfo=pytz.utc)),
        months=3,
    ) == (
        month_to_index(2015, 11),
        month_to_index(2016, 1),
    )
示例#2
0
def test_calendar_range():
    assert get_calendar_range(
        (None, datetime(2016, 2, 1, tzinfo=pytz.utc)),
        months=3,
    ) == (
        month_to_index(2015, 11),
        month_to_index(2016, 1),
    )
示例#3
0
def test_month_indexing():
    assert index_to_month(month_to_index(1986, 10)) == (1986, 10)
示例#4
0
def test_month_indexing():
    assert index_to_month(month_to_index(1986, 10)) == (1986, 10)