As mentioned in #37, the majority of the current tests are integration tests, communicating via the API with a photo/frontend server. Multiple test servers can be used to validate against different server/API versions.
While this is a useful strategy for flushing out issues and generally making sure the API doesn't accidentally get broken, it would also be useful to have a wider variety of unit tests that don't require a server connection.
In particular:
Get/Post testing of openphoto_http.py
Each API endpoint
The commandline interface
The goal should be to mock at the socket level (eg. Httpretty).
Once we have good unit test coverage, we can use Travis to run unit tests, and run the integration tests manually as required.
As mentioned in #37, the majority of the current tests are integration tests, communicating via the API with a photo/frontend server. Multiple test servers can be used to validate against different server/API versions.
While this is a useful strategy for flushing out issues and generally making sure the API doesn't accidentally get broken, it would also be useful to have a wider variety of unit tests that don't require a server connection.
In particular:
The goal should be to mock at the socket level (eg. Httpretty).
Once we have good unit test coverage, we can use Travis to run unit tests, and run the integration tests manually as required.