points.add(p1);
points.add(p2);
points.add(p4);
LineString ls = new LineString(points);
CoordSeqEditor les=new CoordSeqEditor(ls.getPoints());
les.tryInsertPoint(p3);
LineString ls2 = new LineString(les.toCoordinateSeq());
CoordSeqEditor les2=new CoordSeqEditor(ls.getPoints());
les.tryInsertPoint(p2);
LineString ls3 =new LineString(les2.toCoordinateSeq());
String exp2 = "LINESTRING(10.0 20.0,20.0 40.0,30.0 60.0,40.0 80.0)";
assertTrue(exp2.equals(ls2.toString()));
String exp3 = "LINESTRING(10.0 20.0,30.0 60.0,40.0 80.0)";
assertTrue(exp3.equals(ls3.toString()));