test_cli.py 文件源码

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

项目:histonets-cv 作者: sul-cidr 项目源码 文件源码
def test_command_graph_gexf_tolerance(self):
        matches = [
            ((0, 0), (3, 3)),
            ((1, 11), (4, 14)),
            ((8, 12), (11, 15)),
        ]
        regions = utils.serialize_json(matches)
        result = self.runner.invoke(
            cli.graph,
            [regions, '-f', 'gexf', '-st', 0, self.image_grid]
        )
        out = nx.read_gexf(io.StringIO(result.output.strip()))
        graph = nx.read_gexf(fixtures_path('graph.gexf'))
        assert nodeset(out) == nodeset(graph)
        assert edgeset(out) == edgeset(graph)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号