Example #1
0
def test_when_false():
    assert three_to_sum([20, 303, 3, 4, 25], 100) is False
Example #2
0
def test_given_example():
    assert three_to_sum([20, 303, 3, 4, 25], 49) is True
Example #3
0
def test_simple():
    assert three_to_sum([1, 2, 3, 4], 9) is True
Example #4
0
def test_if_one_number_is_used_once():
    assert three_to_sum([2, 4, 5], 6) is False
Example #5
0
def test_discontinuous_nums_when_sorted():
    assert three_to_sum([20, 303, 3, 4, 25, 7, 21], 49) is True
Example #6
0
def test_when_too_few_to_sum():
    assert three_to_sum([24, 303, 3, 25], 49) is False
Example #7
0
def test_when_too_many_to_sum():
    assert three_to_sum([20, 303, 3, 2, 2, 25], 49) is False
Example #8
0
def test_when_zero():
    assert three_to_sum([], 0) is False
    assert three_to_sum([20, 303, 3, 4, 25], 0) is False