diff --git a/js/id/renderer/map.js b/js/id/renderer/map.js index 8ac6e494d..bfd11d1ac 100644 --- a/js/id/renderer/map.js +++ b/js/id/renderer/map.js @@ -81,6 +81,8 @@ iD.Map = function() { map.size(this.size()); hideInspector(); + + map.surface = surface; } map.history = iD.History(); @@ -532,7 +534,6 @@ iD.Map = function() { return map; }; - map.surface = surface; map.background = background; map.projection = projection; map.redraw = redraw; diff --git a/test/spec/Map.js b/test/spec/Map.js index 53672d318..40ecd50b4 100644 --- a/test/spec/Map.js +++ b/test/spec/Map.js @@ -60,4 +60,10 @@ describe('Map', function() { expect(map.extent()[1][0]).toBeCloseTo(36); }); }); + + describe("surface", function() { + it("is an SVG element", function() { + expect(map.surface.node().tagName).toEqual("svg"); + }); + }); });