Change new problem script boiler plate
This commit is contained in:
@@ -6,7 +6,16 @@ class Solution:
|
|||||||
pass
|
pass
|
||||||
EOF
|
EOF
|
||||||
cat > "$d/solution_test.py" <<'EOF'
|
cat > "$d/solution_test.py" <<'EOF'
|
||||||
|
import pytest
|
||||||
from solution import Solution
|
from solution import Solution
|
||||||
def test_solve():
|
|
||||||
assert Solution().solve() is None
|
|
||||||
|
@pytest.mark.parametrize(
|
||||||
|
"X,expected",
|
||||||
|
[
|
||||||
|
([2, 7, 11, 15], [0, 1]),
|
||||||
|
],
|
||||||
|
)
|
||||||
|
def test_REPLACE(X, expected):
|
||||||
|
assert Solution().REPLACE(X, expected) == expected
|
||||||
EOF
|
EOF
|
||||||
|
|||||||
Reference in New Issue
Block a user