Doctest enabling

This PR addresses #61 and fixes the failing examples.