Pass local module to a function?

I’m trying to create a minimal working example of a Documenter error I’m experiencing. However I’m having trouble passing the “local” module to the doctest function, This is what I’m trying:

using Documenter

module Foo

function foo()
end

end

doctest(Foo)

I’ve also tried “.Foo”, “…Foo”, “…Foo”, and “Main.Foo”. Is this even possible? Or do I need to create a module somewhere and use Pkg to add it?

I figured it out. It appears you need to do:

doctest(nothing, [Foo])

Looking at the source for Documenter this bypasses the pathof(package) code in the other doctest() method and it’s happish.

1 Like