Exemplo n.º 1
0
def tests_for_hw2_solution1():
    u"""Набор простых тестов для решения задачи 1 ДЗ#2"""
    assert hw2_solution1.squares_1([1, 2, 3]) == [1, 4, 9]  # "assert" проверяет является ли True переданное выражение
    assert hw2_solution1.squares_1((1, 2, 3)) == (1, 4, 9)
    assert hw2_solution1.squares_2([1, 2, 3]) == [1, 4, 9]
    assert hw2_solution1.squares_2((1, 2, 3)) == (1, 4, 9)
    assert hw2_solution1.squares_3([1, 2, 3]) == [1, 4, 9]
    assert hw2_solution1.squares_3((1, 2, 3)) == (1, 4, 9)
Exemplo n.º 2
0
def tests_for_hw2_solution1():
    u"""Набор простых тестов для решения задачи 1 ДЗ#2"""
    assert hw2_solution1.squares_1(
        [1, 2,
         3]) == [1, 4,
                 9]  # "assert" проверяет является ли True переданное выражение
    assert hw2_solution1.squares_1((1, 2, 3)) == (1, 4, 9)
    assert hw2_solution1.squares_2([1, 2, 3]) == [1, 4, 9]
    assert hw2_solution1.squares_2((1, 2, 3)) == (1, 4, 9)
    assert hw2_solution1.squares_3([1, 2, 3]) == [1, 4, 9]
    assert hw2_solution1.squares_3((1, 2, 3)) == (1, 4, 9)
Exemplo n.º 3
0
def runner():
    u"""Запускает выполнение всех задач"""
    print INPUT_1, ">>", hw2_solution1.squares_1(INPUT_1)
    print INPUT_1, ">>", hw2_solution1.squares_2(INPUT_1)
    print INPUT_1, ">>", hw2_solution1.squares_3(INPUT_1)

    print INPUT_2A, ">>", hw2_solution2.symmetry_1(INPUT_2A)
    print INPUT_2B, ">>", hw2_solution2.symmetry_2(INPUT_2B)
Exemplo n.º 4
0
def runner():
    u"""Запускает выполнение всех задач"""
    print INPUT_1, ">>", hw2_solution1.squares_1(INPUT_1)
    print INPUT_1, ">>", hw2_solution1.squares_2(INPUT_1)
    print INPUT_1, ">>", hw2_solution1.squares_3(INPUT_1)

    print INPUT_2A, ">>", hw2_solution2.symmetry_1(INPUT_2A)
    print INPUT_2B, ">>", hw2_solution2.symmetry_2(INPUT_2B)