예제 #1
0
    public function testRenderJsContainerPolylines()
    {
        $map = new Map();
        $map->setJavascriptVariable('map');
        $map->addPolyline($polyline = new Polyline());
        $polyline->setJavascriptVariable('polyline');
        $expected = <<<EOF
map_container.polylines.polyline = polyline = new google.maps.Polyline({"map":map,"path":[]});

EOF;
        $this->assertSame($expected, $this->mapHelper->renderJsContainerPolylines($map));
    }