Implement Unit Testing for fancymath
#8
@@ -15,6 +15,14 @@ def fact(n: int) -> int:
|
||||
return n * fact(n - 1)
|
||||
|
||||
|
||||
def is_even(x):
|
||||
return x % 2 == 0
|
||||
|
||||
|
||||
def is_odd(x):
|
||||
return x % 2 == 1
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
n = 5
|
||||
assert fact(n) == 120
|
||||
|
||||
0
test/test_math.py
Normal file
0
test/test_math.py
Normal file
0
test/test_util.py
Normal file
0
test/test_util.py
Normal file
0
test/test_vector.py
Normal file
0
test/test_vector.py
Normal file
Reference in New Issue
Block a user