示例#1
0
    def test_view(self, chart, _chart):
        bl = BaseLine(x="test_x", y="test_y")
        bl.chart = chart
        bl.width = 400

        assert str(bl.view()) == str(chart_view(_chart, width=bl.width))
    def test_view(self, chart, _chart):
        bl = BaseLine(x="test_x", y="test_y")
        bl.chart = mock.Mock(**{"view.return_value": chart})
        bl.width = 400

        assert str(bl.view()) == str(chart_view(_chart, width=bl.width))