@@ -111,23 +111,23 @@ public function testValidatePointsEllipse()
111
111
public function testValidatePointsLine ()
112
112
{
113
113
$ this ->model ->shape_id = Shape::lineId ();
114
- $ this ->model ->validatePoints ([10 , 10 ]);
114
+ $ this ->model ->validatePoints ([10 , 10 , 20 , 20 ]);
115
115
$ this ->expectException (Exception::class);
116
116
$ this ->model ->validatePoints ([10 ]);
117
117
}
118
118
119
119
public function testValidatePointsPolygon ()
120
120
{
121
121
$ this ->model ->shape_id = Shape::polygonId ();
122
- $ this ->model ->validatePoints ([10 , 10 ]);
122
+ $ this ->model ->validatePoints ([10 , 10 , 20 , 20 , 30 , 30 , 10 , 10 ]);
123
123
$ this ->expectException (Exception::class);
124
- $ this ->model ->validatePoints ([10 ]);
124
+ $ this ->model ->validatePoints ([10 , 10 ]);
125
125
}
126
126
127
127
public function testValidatePointsPolygonFirstLastEqual ()
128
128
{
129
129
$ this ->model ->shape_id = Shape::polygonId ();
130
- $ this ->model ->validatePoints ([10 , 10 , 20 , 20 , 10 , 10 ]);
130
+ $ this ->model ->validatePoints ([10 , 10 , 20 , 20 , 30 , 30 , 10 , 10 ]);
131
131
$ this ->expectException (Exception::class);
132
132
$ this ->model ->validatePoints ([10 , 10 , 20 , 20 , 30 , 30 ]);
133
133
}
0 commit comments