Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion calc/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ def div(a, b):
return a

def mul(a, b):
return b
"""
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Incorrect indentation

Returns the product of A and B
"""
return a * b
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add tests for this functionality.


def mod(a, b):
res = a % b
Expand Down
6 changes: 5 additions & 1 deletion calc/tests/test_calc.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
from calc import add
from calc import add, mul

def test_add():
assert add(1, 2) == 3

def test_mul():
assert mul(2, -3) == -6
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also incorrectly indented