Ejemplo n.º 1
0
def test_split_digits(
    one_to_nine,
    digit_1,
    digit_2,
    digit_3,
    digit_4,
    digit_5,
    digit_6,
    digit_7,
    digit_8,
    digit_9,
):
    digits = _split_digits(one_to_nine)
    assert (
        len(digits) == 9
        and all(isinstance(d, Digit) for d in digits)
        and digits[0] == digit_1
        and digits[1] == digit_2
        and digits[2] == digit_3
        and digits[3] == digit_4
        and digits[4] == digit_5
        and digits[5] == digit_6
        and digits[6] == digit_7
        and digits[7] == digit_8
        and digits[8] == digit_9
    )
Ejemplo n.º 2
0
def nine() -> Digit:
    return _split_digits(_get_from_order(ZERO_TO_NINE, 9))[0]
Ejemplo n.º 3
0
def eight() -> Digit:
    return _split_digits(_get_from_order(ZERO_TO_NINE, 8))[0]
Ejemplo n.º 4
0
def seven() -> Digit:
    return _split_digits(_get_from_order(ZERO_TO_NINE, 7))[0]
Ejemplo n.º 5
0
def six() -> Digit:
    return _split_digits(_get_from_order(ZERO_TO_NINE, 6))[0]
Ejemplo n.º 6
0
def five() -> Digit:
    return _split_digits(_get_from_order(ZERO_TO_NINE, 5))[0]
Ejemplo n.º 7
0
def four() -> Digit:
    return _split_digits(_get_from_order(ZERO_TO_NINE, 4))[0]
Ejemplo n.º 8
0
def three() -> Digit:
    return _split_digits(_get_from_order(ZERO_TO_NINE, 3))[0]
Ejemplo n.º 9
0
def two() -> Digit:
    return _split_digits(_get_from_order(ZERO_TO_NINE, 2))[0]