Skip to content

Commit cef768d

Browse files
committed
Added test_if_then_elif_else_statements
1 parent 29bca23 commit cef768d

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

python2/koans/about_control_statements.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,16 @@ def test_if_then_statements(self):
1818
if True:
1919
result = 'true value'
2020
self.assertEqual(__, result)
21+
22+
def test_if_then_elif_else_statements(self):
23+
result = 'default value'
24+
if False:
25+
result = 'first value'
26+
elif True:
27+
result = 'true value'
28+
else:
29+
result = 'default value'
30+
self.assertEqual(__, result)
2131

2232
def test_while_statement(self):
2333
i = 1

0 commit comments

Comments
 (0)