コード例 #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
ファイル: test_reports.py プロジェクト: faulkner/sentry
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
ファイル: test_reports.py プロジェクト: alshopov/sentry
def test_month_indexing():
    assert index_to_month(month_to_index(1986, 10)) == (1986, 10)