コード例 #1
0
ファイル: test_features.py プロジェクト: olibchr/folium
def test_figure_rendering():
    f = features.Figure()
    out = f.render()
    assert type(out) is text_type

    bounds = f.get_bounds()
    assert bounds == [[None, None], [None, None]], bounds
コード例 #2
0
ファイル: test_features.py プロジェクト: olibchr/folium
def test_figure_double_rendering():
    f = features.Figure()
    out = f.render()
    out2 = f.render()
    assert out == out2

    bounds = f.get_bounds()
    assert bounds == [[None, None], [None, None]], bounds
コード例 #3
0
ファイル: test_features.py プロジェクト: sale2210/folium
def test_figure_html():
    f = features.Figure()
    out = f.render()
    out = os.linesep.join([s.strip() for s in out.splitlines() if s.strip()])
    assert out.strip() == tmpl.strip(), '\n' + out.strip() + '\n' + '-' * 80 + '\n' + tmpl.strip()  # noqa

    bounds = f.get_bounds()
    assert bounds == [[None, None], [None, None]], bounds
コード例 #4
0
def test_figure_html():
    f = features.Figure()
    out = f.render()
    out = os.linesep.join([s for s in out.splitlines() if s.strip()])
    print(out)
    assert out.strip() == tmpl.strip()

    bounds = f.get_bounds()
    assert bounds == [[None, None], [None, None]], bounds
コード例 #5
0
ファイル: test_features.py プロジェクト: olibchr/folium
def test_figure_creation():
    f = features.Figure()
    assert isinstance(f, Element)

    bounds = f.get_bounds()
    assert bounds == [[None, None], [None, None]], bounds
コード例 #6
0
ファイル: test_features.py プロジェクト: wagamama/folium
 def test_figure_double_rendering(self):
     f = features.Figure()
     out = f.render()
     out2 = f.render()
     assert out == out2
コード例 #7
0
ファイル: test_features.py プロジェクト: wagamama/folium
 def test_figure_rendering(self):
     f = features.Figure()
     out = f.render()
     assert type(out) is text_type
コード例 #8
0
ファイル: test_features.py プロジェクト: wagamama/folium
 def test_figure_creation(self):
     f = features.Figure()
コード例 #9
0
def test_figure_html():
    f = features.Figure()
    out = f.render()
    out = os.linesep.join([s for s in out.splitlines() if s.strip()])
    print(out)
    assert out.strip() == tmpl.strip()
コード例 #10
0
def test_figure_creation():
    f = features.Figure()
    assert isinstance(f, Element)