Open rgbkrk opened 9 years ago
I like the look of mock-server for mocking a REST endpoint (or whatever, I guess).
We then just generate a serialized dump of our current tests, (maybe make that repeatable) and store it right along with the tests.
had a look through mock-server... didn't look very maintained. github3.py, as was mentioned, rolled (several) of their own. This seems like something that could stand alone eventually, but either bringing github3.py in and using it directly, or cargo-culting could work.
The major issue is that we can't bring in github3.py in directly since we need async futures instead of blocking network calls. (if you're talking client)
If you're talking bringing in the mocks from github3.py to test against, that's another thing.
In our current testing setup, we're doing functional tests with no way to do mocks against GitHub itself. This ends up causing a lot of bad builds when things are actually fine. Since things can time out between requests and nbviewer, I this there's a mismatch.
Using
tornado.testing
should help do tests properly for nbviewer.