Select Git revision
-
Vincent Michel authored
git-svn-id: https://scikit-learn.svn.sourceforge.net/svnroot/scikit-learn/trunk@440 22fbfee3-77ab-4535-9bad-27d1bd3bc7d8
Vincent Michel authoredgit-svn-id: https://scikit-learn.svn.sourceforge.net/svnroot/scikit-learn/trunk@440 22fbfee3-77ab-4535-9bad-27d1bd3bc7d8
assert_tests.py 448 B
# ==============
# File: assert_tests.py
# By: Jack Holdsworth - 20023933
# Use: Using the assert function to test morse.py
# Written on: Python 3.8
# ==============
import morse
def test_encode_us():
assert morse.encode('us') == '..- ...', "Should be ..- ..."
def test_decode_us():
assert morse.decode('..- ...') == 'US', "Should be us"
if __name__ == "__main__":
test_encode_us()
test_decode_us()
print('Everything passed')