One possible approach: Use the autodoc-skip-member event from
autodoc.  If you assign an attribute, say "_category" to each of your
test functions/classes, with the category name, and use the `obj`
argument of the autodoc-skip-member to determine if it should be shown
or not...

On Oct 29, 2:16 am, sebastien piquemal <seb...@gmail.com> wrote:
> Hi !
>
> Ok ... here is what I am trying to do :
>
>     I have a 'tests.py' file, and these tests are separated under
> several categories. What I would like to do, is insert each category
> of tests in different doc pages, without having to split the source in
> several python files.
>
>     I have tried different approaches, but with no result :
>         - literalinclude : which doesn't work, because the tests.py
> file is not under the "doc source root"
>         - declaring these tests as docstrings of classes : class
> base_tests: """ my tests ...""" pass
>          insert those with .. autoclass:: tests.base_tests
>          and that's not good either, because now I have the header of
> the class definition in my doc page...
>
> Do somebody have a solution to solve this problem ?

-- 
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-...@googlegroups.com.
To unsubscribe from this group, send email to 
sphinx-dev+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en.

Reply via email to