Travis-CI: propagate tests failures back to Travis

The problem was that somehow the nonzero exit code was not always propagated to
Travis. I have found that using just one executable statement fixes it. So now
we run both tests and doctests using one Python session.
Merge pull request #1758 from certik/travis_fix

Travis-CI: propagate tests failures back to Travis