Skip to content

Commit b643a99

Browse files
committed
Solved warnings.
1 parent 6ba6ca8 commit b643a99

File tree

2 files changed

+11
-10
lines changed

2 files changed

+11
-10
lines changed

folium/features.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -688,7 +688,8 @@ def __init__(self, bounds, color='black', weight=1, fill_color='black',
688688
689689
Example
690690
-------
691-
>>> RectangleMarker(bounds=[[35.681, 139.766], [35.691, 139.776]], color="blue", fill_color="red", popup='Tokyo, Japan')
691+
>>> RectangleMarker(bounds=[[35.681, 139.766], [35.691, 139.776]],
692+
color="blue", fill_color="red", popup='Tokyo, Japan')
692693
"""
693694
super(RectangleMarker, self).__init__(bounds, popup=popup)
694695
self._name = 'RectangleMarker'
@@ -764,6 +765,7 @@ def __init__(self, locations, color='black', weight=1, fill_color='black',
764765
{% endmacro %}
765766
""")
766767

768+
767769
class LatLngPopup(MacroElement):
768770
"""
769771
When one clicks on a Map that contains a LatLngPopup,

tests/test_folium.py

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ def test_rectangle_marker(self):
245245
rect_templ = self.env.get_template('rectangle_marker.js')
246246

247247
# Single Rectangle marker.
248-
bounds=[45.60, -122.8, 45.61, -122.7]
248+
bounds = [45.60, -122.8, 45.61, -122.7]
249249
self.map.add_child(folium.RectangleMarker(bounds=bounds, popup='Hi'))
250250
marker = list(self.map._children.values())[-1]
251251
rect_1 = rect_templ.render({'RectangleMarker': marker.get_name(),
@@ -258,7 +258,7 @@ def test_rectangle_marker(self):
258258
''.join(self.map.get_root().render().split()))
259259

260260
# Second Rectangle marker.
261-
bounds=[45.70, -122.9, 45.75, -122.5]
261+
bounds = [45.70, -122.9, 45.75, -122.5]
262262
self.map.add_child(folium.RectangleMarker(bounds=bounds, popup='Hi'))
263263
marker = list(self.map._children.values())[-1]
264264
rect_2 = rect_templ.render({'RectangleMarker': marker.get_name(),
@@ -291,11 +291,11 @@ def test_polygon(self):
291291
self.map.add_child(folium.Polygon(locations=locations, popup='Hi'))
292292
marker = list(self.map._children.values())[-1]
293293
polygon_1 = polygon_templ.render({'Polygon': marker.get_name(),
294-
'location': locations,
295-
'color': 'black',
296-
'fill_color': 'black',
297-
'fill_opacity': 0.6,
298-
'weight': 1})
294+
'location': locations,
295+
'color': 'black',
296+
'fill_color': 'black',
297+
'fill_opacity': 0.6,
298+
'weight': 1})
299299
assert (''.join(polygon_1.split())[:-1] in
300300
''.join(self.map.get_root().render().split()))
301301

@@ -309,7 +309,7 @@ def test_polygon(self):
309309
[35.5682, 138.7588],
310310
[35.5663, 138.7627]]
311311
self.map.add_child(folium.Polygon(locations=locations, color='red',
312-
fill_color='red', fill_opacity=0.7,
312+
fill_color='red', fill_opacity=0.7,
313313
weight=3, popup='Hi'))
314314
marker = list(self.map._children.values())[-1]
315315
polygon_2 = polygon_templ.render({'Polygon': marker.get_name(),
@@ -325,7 +325,6 @@ def test_polygon(self):
325325
assert bounds == [[[35.5636, 138.7634], [35.5629, 138.7664]],
326326
[[35.6636, 139.7634], [35.6629, 139.7664]]], bounds
327327

328-
329328
def test_poly_marker(self):
330329
"""Test polygon marker."""
331330

0 commit comments

Comments
 (0)