is_dog_in is expected to evaluate to False, and since __ is defined as False at the top of the file, the second assertion in the test passes without the student having to change __ to False. (this assumes that the first assertion in the test has already been fixed)
|
def test_if_a_string_contains_another_string(self): |
|
|
|
string = "Pears, lettuce and tomato" |
|
is_lettuce_in = "lettuce" in string |
|
|
|
assert is_lettuce_in == __ |
|
|
|
is_dog_in = "dog" in string |
|
|
|
assert is_dog_in == __ |