nteract / bookstore

📚 Notebook storage and publishing workflows for the masses
https://bookstore.readthedocs.io
BSD 3-Clause "New" or "Revised" License
201 stars 23 forks source link

Ensure that finish is called in async RequestHandler tests #133

Open mpacer opened 5 years ago

mpacer commented 5 years ago

This issue arose as part of #130, specifically as I discovered that we were running into a new set of errors when testing a method on a synchronous handler.

Some of the comments I added relate, but it comes down to needing to await those methods

await handler.get() where it is currently handler.get().

This is especially important for success tests.

The issue that comes up has to do with whether self._transforms has been set by the application or not by the time self.flush() is called. Given that the Application is a mock application and isn't calling a handler delegate this seems to not be set by default in our current mock framework.