Improve usage of doctest directives