pytester.py 文件源码

python
阅读 26 收藏 0 点赞 0 评论 0

项目:hostapd-mana 作者: adde88 项目源码 文件源码
def parseconfig(self, *args):
        """Return a new pytest Config instance from given commandline args.

        This invokes the pytest bootstrapping code in _pytest.config
        to create a new :py:class:`_pytest.core.PluginManager` and
        call the pytest_cmdline_parse hook to create new
        :py:class:`_pytest.config.Config` instance.

        If :py:attr:`plugins` has been populated they should be plugin
        modules which will be registered with the PluginManager.

        """
        args = self._ensure_basetemp(args)

        import _pytest.config
        config = _pytest.config._prepareconfig(args, self.plugins)
        # we don't know what the test will do with this half-setup config
        # object and thus we make sure it gets unconfigured properly in any
        # case (otherwise capturing could still be active, for example)
        self.request.addfinalizer(config._ensure_unconfigure)
        return config
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号