test_passive.py 文件源码

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

项目:no-YOU-talk-to-the-hand 作者: flashashen 项目源码 文件源码
def test_basic_config():


    fd, path = tempfile.mkstemp()
    f = os.fdopen(fd,'w')
    f.write(yaml.dump(testcfg))
    f.flush()

    cfg = ny.get_config(path)
    ny.write_supervisor_conf()

    config = ConfigParser.ConfigParser()
    config.readfp(open(cfg['supervisor.conf']))

    # from IPython import embed
    # embed()
    print(config.get('program:testtunnel','command'))
    assert 'sshuttle -r 1.1.1.1 2.2.2.2 -x 3.3.3.3' in config.get('program:testtunnel','command')
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号