Location\PolygonTest::testIfContainsPointCheckWorksAsExpected PHP Method

testIfContainsPointCheckWorksAsExpected() public method

    public function testIfContainsPointCheckWorksAsExpected()
    {
        $polygon = new Polygon();
        $polygon->addPoint(new Coordinate(10, 20));
        $polygon->addPoint(new Coordinate(10, 40));
        $polygon->addPoint(new Coordinate(30, 40));
        $polygon->addPoint(new Coordinate(30, 20));
        $point = new Coordinate(20, 30);
        $this->assertTrue($polygon->contains($point));
    }