Closed wbushey closed 4 years ago
Hi @wbushey, thanks for the fix. Would you mind addressing the Travis failure before I pull? Thanks.
@wbushey, also in my build I'm seeing mock is missing. Could it be a missing requirement or some other setup change that's required?
py.test
===================================================================================== test session starts =====================================================================================
platform linux2 -- Python 2.7.15+, pytest-3.7.1, py-1.5.4, pluggy-0.7.1
rootdir: /home/jeff/Dropbox/workspace/geeknote, inifile:
collected 109 items / 1 errors
=========================================================================================== ERRORS ============================================================================================
____________________________________________________________________________ ERROR collecting tests/test_gnsync.py ____________________________________________________________________________ImportError while importing test module '/home/jeff/Dropbox/workspace/geeknote/tests/test_gnsync.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
tests/test_gnsync.py:2: in <module>
from mock import patch, ANY, Mock
E ImportError: No module named mock
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 1 errors during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!=================================================================================== 1 error in 0.71 seconds ===================================================================================
I added mock to requirements.txt, so when running the tests locally, you're going to need to first run pip install -r requirements.txt
. That should take care of finding mock.
As for the error in Travis, I think I see what is happening. I need to mock out Storage().getUserToken()
in the test I added so that GNSync can be instantiated. I should be able to do that pretty quickly.
Just started using GeekNote, and I'm really liking it. Ran into #109 while syncing some notes; this fix has worked for me for the last few days.