コード例 #1
0
def second_field_valid_range_with_step(second_valid_range_with_step):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    by a valid range of numbers with a step.
    """
    return field.second(second_valid_range_with_step)
コード例 #2
0
def second_field_valid_numeral(second_valid_numeral):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    with a valid numeral.
    """
    return field.second(second_valid_numeral)
コード例 #3
0
def second_field_valid_numeral_as_str(second_valid_numeral):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    with a valid numeral as a string.
    """
    return field.second(compat.str(second_valid_numeral))
コード例 #4
0
def second_field_valid_list_csv_str(second_valid_list):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    with a valid list of numerals formatted as a comma separated string.
    """
    return field.second(','.join(map(str, second_valid_list)))
コード例 #5
0
def test_default_second_field_matches_all_numeral_values(second_valid_numeral):
    """
    Assert that the "second" field with the default value matches all numeral values within
    bounds inclusively.
    """
    assert field.second(field.DEFAULT_VALUE).matches(second_valid_numeral)
コード例 #6
0
def second_field_valid_range_with_step_str(second_valid_range_with_step_str):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    by a valid range string with a step value.
    """
    return field.second(second_valid_range_with_step_str)
コード例 #7
0
def second_field_all_match_range_with_step_str(request):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    by a valid "all matches" range string with a step value.
    """
    return field.second('*/{0}'.format(request.param))
コード例 #8
0
ファイル: test_field.py プロジェクト: ahawker/crython
def second_field_valid_numeral_as_str(second_valid_numeral):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    with a valid numeral as a string.
    """
    return field.second(compat.str(second_valid_numeral))
コード例 #9
0
ファイル: test_field.py プロジェクト: ahawker/crython
def second_field_valid_range_with_step(second_valid_range_with_step):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    by a valid range of numbers with a step.
    """
    return field.second(second_valid_range_with_step)
コード例 #10
0
ファイル: test_field.py プロジェクト: ahawker/crython
def second_field_valid_numeral(second_valid_numeral):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    with a valid numeral.
    """
    return field.second(second_valid_numeral)
コード例 #11
0
ファイル: test_field.py プロジェクト: ahawker/crython
def test_default_second_field_matches_all_numeral_values(second_valid_numeral):
    """
    Assert that the "second" field with the default value matches all numeral values within
    bounds inclusively.
    """
    assert field.second(field.DEFAULT_VALUE).matches(second_valid_numeral)
コード例 #12
0
ファイル: test_field.py プロジェクト: ahawker/crython
def second_field_valid_list_csv_str(second_valid_list):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    with a valid list of numerals formatted as a comma separated string.
    """
    return field.second(','.join(map(str, second_valid_list)))
コード例 #13
0
ファイル: test_field.py プロジェクト: ahawker/crython
def second_field_all_match_range_with_step_str(request):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    by a valid "all matches" range string with a step value.
    """
    return field.second('*/{0}'.format(request.param))
コード例 #14
0
ファイル: test_field.py プロジェクト: ahawker/crython
def second_field_valid_range_with_step_str(second_valid_range_with_step_str):
    """
    Fixture that yields back a :class:`~crython.field.CronField` for the "second" field created
    by a valid range string with a step value.
    """
    return field.second(second_valid_range_with_step_str)