Skip to content

Commit f35edee

Browse files
committed
Added tests/ directory with test_add_junk.py
1 parent 37e4ba2 commit f35edee

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

tests/test_add_junk.py

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# import sys
2+
3+
# sys.path.append("/Users/richardevans/Docs/Economics/OSE/CompMethods/code/")
4+
5+
import pytest
6+
7+
# from junk_funcs import junk_func_add
8+
9+
10+
def junk_func_add(arg1, arg2):
11+
"""
12+
This is just a junk function that duplicates the `junk_funcs.py` module in
13+
the `/code/` directory. We can delete this as soon as we have some real
14+
functions.
15+
"""
16+
junk_sum = arg1 + arg2
17+
18+
return junk_sum
19+
20+
21+
@pytest.mark.parametrize(
22+
"arg1, arg2, expected",
23+
[(2, 3, 5), (10, 17, 27)],
24+
ids=[
25+
"2 plus 3 equals 5",
26+
"10 plus 17 equals 27",
27+
],
28+
)
29+
def test_junk_func_add(arg1, arg2, expected):
30+
"""
31+
This is just a fake test of code in the `/code/` directory. We can delete
32+
this as soon as we have some real tests.
33+
"""
34+
junk_sum = junk_func_add(arg1, arg2)
35+
36+
assert junk_sum == expected

0 commit comments

Comments
 (0)