Add flask-testing extension and unit tests for models