@Ignore
@Test
public void testDrawLine() {
handler.getMouseTracker().setDragStarted(Point.valueOf(0,10));
MapMouseEvent event=new MapMouseEvent(null, 10,10,MapMouseEvent.NONE,MapMouseEvent.BUTTON1, MapMouseEvent.BUTTON1);
handler.handleEvent(event, EventType.DRAGGED);
assertTrue(handler.isLocked());
assertNotNull(handler.getCurrentShape());
assertEquals(EditState.CREATING, handler.getCurrentState());
event=new MapMouseEvent(null, 20,10,MapMouseEvent.NONE,MapMouseEvent.BUTTON1, MapMouseEvent.BUTTON1);
handler.handleEvent(event, EventType.DRAGGED);
handler.handleEvent(event, EventType.RELEASED);
assertFalse(handler.isLocked());
assertEquals(Point.valueOf(0,10), handler.getCurrentShape().getPoint(0));
assertEquals(Point.valueOf(10,10), handler.getCurrentShape().getPoint(1));
assertEquals(Point.valueOf(20,10), handler.getCurrentShape().getPoint(2));
assertEquals(ShapeType.LINE, handler.getCurrentGeom().getShapeType());
assertFalse( acceptor.ran);
//continue line
PrimitiveShape currentShape = handler.getCurrentShape();
handler.getMouseTracker().setDragStarted(Point.valueOf(20,11));
event=new MapMouseEvent(null, 30,10,MapMouseEvent.NONE,MapMouseEvent.BUTTON1, MapMouseEvent.BUTTON1);
handler.handleEvent(event, EventType.DRAGGED);
handler.handleEvent(event, EventType.RELEASED);
assertEquals(currentShape, handler.getCurrentShape());
assertEquals(Point.valueOf(0,10), handler.getCurrentShape().getPoint(0));
assertEquals(Point.valueOf(10,10), handler.getCurrentShape().getPoint(1));
assertEquals(Point.valueOf(20,10), handler.getCurrentShape().getPoint(2));
assertEquals(Point.valueOf(30,10), handler.getCurrentShape().getPoint(3));
//start a new line
acceptor.ran=false;
handler.getMouseTracker().setDragStarted(Point.valueOf(100,10));
event=new MapMouseEvent(null, 100,20,MapMouseEvent.NONE,MapMouseEvent.BUTTON1, MapMouseEvent.BUTTON1);
handler.handleEvent(event, EventType.DRAGGED);
handler.handleEvent(event, EventType.RELEASED);
assertEquals(Point.valueOf(100,10), handler.getCurrentShape().getPoint(0));