With widespread use of Jupyter Notebooks, it becomes important to write maintainable and reliable notebooks. testbook helps you unit test your notebooks in the conventional unit testing style, with the tests existing as a separate entity.
electronics engineering student - Google Summer of Code 2020 student working on testbook under the mentorship of Matthew Seal (@codeseal) - Love Python and C github.com/rohitsanj @imrohitsanj rohitsanjay.com
data science experiments in Jupyter Notebooks can get messy. Enforcing good coding habits in Jupyter Notebooks can lead to maintainable and easily refactorable code. Some good habits are.. • Use functions to abstract away complexity • Smuggle code out of Jupyter notebooks as soon as possible • Apply test driven development • Make small and frequent commits Source: https://www.thoughtworks.com/insights/blog/coding-habits-data-scientists
Execute all or some speciﬁc cells before unit test • Share kernel context across multiple tests (using pytest ﬁxtures) • Inject code into Jupyter notebooks • Works with any unit testing library - pytest, unittest or nose