Chen Wei 1 year ago
parent 68e5533cfe commit 3bc50b3245c64e74e8c206457ff234d20b6f0f69
1 changed files with 11 additions and 0 deletions
+11-0test_solutions.py ADDED
View File
@@ -0,0 +1,11 @@
1+from two_sum import two_sum
2+from valid_parentheses import is_valid
3+
4+
5+def test_two_sum():
6+ assert two_sum([2, 7, 11, 15], 9) == [0, 1]
7+
8+
9+def test_valid():
10+ assert is_valid("()[]{}")
11+ assert not is_valid("(]")