converted prior circle test to use polygon instead to test shape-margin extending past the margin box