mirror of
https://github.com/donnemartin/interactive-coding-challenges.git
synced 2024-03-22 13:11:13 +08:00
18 lines
484 B
Python
18 lines
484 B
Python
|
from nose.tools import assert_equal
|
||
|
|
||
|
|
||
|
class TestReverse(object):
|
||
|
|
||
|
def test_reverse(self):
|
||
|
assert_equal(list_of_chars(None), None)
|
||
|
assert_equal(list_of_chars(['']), [''])
|
||
|
assert_equal(list_of_chars(['f', 'o', 'o', ' ', 'b', 'a', 'r']),
|
||
|
['r', 'a', 'b', ' ', 'o', 'o', 'f'])
|
||
|
print('Success: test_reverse')
|
||
|
|
||
|
def main():
|
||
|
test = TestReverse()
|
||
|
test.test_reverse()
|
||
|
|
||
|
if __name__ == '__main__':
|
||
|
main()
|