Fix bug #477; POLYEND now throws an error if the polygon has two vertices (same as if the polygon has one vertex).
This revision also includes many new regression tests for the polygon API.
Authored by: david_costanzo 2016-07-04
Parent: [r4149]
Child: [r4151]