How to create autodoc with sphinx on a pytest marked class?

  pytest, python, sphinx

Having such class marked with pytest.mark.parametrize:

@pytest.mark.parametrize('app_lang', MobileAppLanguageMark.all(), scope='session')
class MobileBaseCase(BaseCase):
    def foo(self, a, b):
        """
        assadasdasda
        """
    return a,b

I’m trying to use sphinx autodoc to generate the docs.
This is mobile_base_case.rst file:

MobileBaseCase
=========================

.. autoclass:: plugin.lib.mobile.common.mobile_base_case.MobileBaseCase
   :members:
   :undoc-members:
   :show-inheritance:

The resulting html file after make html has only
enter image description here

I’ve also tried using

.. automethod:: foo(self, a, b)
.. automethod:: plugin.lib.mobile.common.mobile_base_case.MobileBaseCase.foo(self, a, b)

but with no luck.

Is there a way to make autodoc ignore the mark and generate docs for MobileBaseCase class?

Source: Python Questions

LEAVE A COMMENT