testing
unittest
deadbeef/
βββ src
β βββ anothermodule
β β βββ anotherscript.py
β βββ module
β βββ script.py
βββ test
βββ __init__.py
βββ test_anothermodule
β βββ __init__.py
β βββ test_anotherscript.py
βββ test_module
βββ __init__.py
βββ test_script.pyimport unittest
import src.module.script
class TestScript(unittest.TestCase):
def test_plus_one(self):
res = src.module.script.plus_one(0)
self.assertEqual(res, 1)
if __name__ == '__main__':
unittest.main()pytest
Last updated