better use of the doctest lib