RunestoneComponents
RunestoneComponents copied to clipboard
AttributeError: module 'test' has no attribute 'testEqual'
Error reported in course thinkcspy on page UnitTesting by user moath.othman [email protected] I entered the following code from the Unit Testing section, URL below: https://runestone.academy/runestone/static/thinkcspy/Functions/UnitTesting.html
Code: def square(x): '''raise x to the second power''' return x * x
import test print('testing square function') test.testEqual(square(10), 100)
When I entered in my Python IDLE v3.6.5, I get the following error:
AttributeError: module 'test' has no attribute 'testEqual'
Please help update the code.
This is still an issue.
Please see: https://runestone.academy/ns/books/published/thinkcspy/Appendices/testmodule.html