test_regendoc.py 文件源码

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

项目:devpi 作者: devpi 项目源码 文件源码
def example(tmpdir):
    p = tmpdir.join("example.txt")
    p.write(py.std.textwrap.dedent("""\
        a simple test function call with one argument factory
        ==============================================================

        the function argument.  Let's look at a simple self-contained
        example that you can put into a test module::

            # content of: test_simplefactory.py
            def pytest_funcarg__myfuncarg(request):
                return 42

            def test_function(myfuncarg):
                assert myfuncarg == 17

        .. code-block:: bash

            $ py.test test_simplefactory.py

            output should be here - but thats nice for testing

        the end.
    """))
    return p
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号