       subLng = initialCenter.lng + ' - ' + location.lng
       lngIsNear = isNear subLng
       return "#{latIsNear} && #{lngIsNear}"
+    containsBbox = (bbox) ->
+      MAP_BOUNDS = 'app.getRegion("map").currentView.map.getBounds()'
+      BBOX_BOUNDS = "new L.LatLngBounds( new L.LatLng(#{bbox.sw}), new L.LatLng(#{bbox.ne}))"
+      return "#{MAP_BOUNDS}.contains(#{BBOX_BOUNDS})"
+    containsPoint = (point) ->
+      MAP_BOUNDS = 'app.getRegion("map").currentView.map.getBounds()'
+      POINT = "new L.LatLng(#{point.lat}, #{point.lng})"
+      return "#{MAP_BOUNDS}.contains(#{POINT})"
     describe 'Test embedded addresses', ->
       embeds = [
         {

          it 'Should display popup with correct street address', (done) ->
            browser
            .get(embedUrl + embed.path)
            .waitForElementByCssSelector(
                '.leaflet-popup-content > .unit-name',
                asserters.isDisplayed,
                delay,
                pollFreq,
              (err, el) ->
                el.text (err, text) -> text.should.equal(embed.name)
            )
            .should.notify done

          it 'Should display marker for address', (done) ->
            browser
              .waitForElementByCssSelector(
                '.leaflet-overlay-pane svg path.leaflet-clickable',
                asserters.isDisplayed,
                delay,
                pollFreq
              )
              .should.notify(done)


                delay, pollFreq))
                .should.notify(done)
        return
    describe 'Test embedded units', ->
      embeds = [
        {
