added new test, moving methods from views to methods.py