Program: 95823
Project: 95823
Buggy source:
/** 
 * Implementation of the mouse move. The mouse is moved into the graphics component.
 * @param graphicsComponent The component to move to
 * @param constraints The more specific constraints. Use this, for example when you want the click point to be relative to a part of the component (e.g. tree node, table cell, etc) rather than the overall component itself. May be <code>null</code>.
 * @param xPos xPos in component
 * @param yPos yPos in component
 * @param xAbsolute true if x-position should be absolute
 * @param yAbsolute true if y-position should be absolute
 * @param clickOptions The click options
 * @throws StepExecutionException If the click delay is interrupted or the event confirmation receives a timeout.
 */
private void moveImpl(final Object graphicsComponent,final Rectangle constraints,final int xPos,final boolean xAbsolute,final int yPos,final boolean yAbsolute,final ClickOptions clickOptions) throws StepExecutionException {
  Rectangle bounds=getComponentBounds(graphicsComponent,clickOptions);
  if (constraints != null) {
    bounds.x+=constraints.x;
    bounds.y+=constraints.y;
    bounds.height=constraints.height;
    bounds.width=constraints.width;
  }
  Point p=PointUtil.calculateAwtPointToGo(xPos,xAbsolute,yPos,yAbsolute,bounds);
  if (isMouseMoveRequired(p)) {
    if (log.isDebugEnabled()) {
      log.debug("String_Node_Str" + p);
    }
    IRobotEventConfirmer confirmer=null;
    if (clickOptions.isConfirmClick()) {
      InterceptorOptions options=new InterceptorOptions(new long[]{AWTEvent.MOUSE_MOTION_EVENT_MASK});
      confirmer=m_interceptor.intercept(options);
    }
    Point startpoint=m_mouseMotionTracker.getLastMousePointOnScreen();
    if (startpoint == null) {
      if (graphicsComponent instanceof Stage) {
        Stage s=(Stage)graphicsComponent;
        Node root=s.getScene().getRoot();
        startpoint=(root != null) ? getLocation(root,null) : new Point(Rounding.round(s.getWidth() / 2),Rounding.round(s.getHeight() / 2));
      }
 else {
        Node node=(Node)graphicsComponent;
        Node root=node.getScene().getRoot();
        Node c=(root != null) ? root : node;
        startpoint=getLocation(c,null);
      }
    }
    final Point[] mouseMove=MouseMovementStrategy.getMovementPath(startpoint,p,clickOptions.getStepMovement(),clickOptions.getFirstHorizontal());
    Point currP=new Point(0,0);
    for (int i=0; i < mouseMove.length; i++) {
      m_robot.mouseMove(mouseMove[i].x,mouseMove[i].y);
      currP.x=mouseMove[i].x;
      currP.y=mouseMove[i].y;
      if (!currP.equals(MouseInfo.getPointerInfo().getLocation())) {
        mouseMoveFallback(currP);
      }
    }
    if (confirmer != null) {
      confirmMove(confirmer,graphicsComponent);
    }
  }
}

Fixed version (ground truth):
/** 
 * Implementation of the mouse move. The mouse is moved into the graphics component.
 * @param graphicsComponent The component to move to
 * @param constraints The more specific constraints. Use this, for example when you want the click point to be relative to a part of the component (e.g. tree node, table cell, etc) rather than the overall component itself. May be <code>null</code>.
 * @param xPos xPos in component
 * @param yPos yPos in component
 * @param xAbsolute true if x-position should be absolute
 * @param yAbsolute true if y-position should be absolute
 * @param clickOptions The click options
 * @throws StepExecutionException If the click delay is interrupted or the event confirmation receives a timeout.
 */
private void moveImpl(final Object graphicsComponent,final Rectangle constraints,final int xPos,final boolean xAbsolute,final int yPos,final boolean yAbsolute,final ClickOptions clickOptions) throws StepExecutionException {
  Rectangle bounds=getComponentBounds(graphicsComponent,clickOptions);
  if (constraints != null) {
    bounds.x+=constraints.x;
    bounds.y+=constraints.y;
    bounds.height=constraints.height;
    bounds.width=constraints.width;
  }
  Point p=PointUtil.calculateAwtPointToGo(xPos,xAbsolute,yPos,yAbsolute,bounds);
  if (isMouseMoveRequired(p)) {
    if (log.isDebugEnabled()) {
      log.debug("String_Node_Str" + p);
    }
    Point startpoint=m_mouseMotionTracker.getLastMousePointOnScreen();
    if (startpoint == null) {
      if (graphicsComponent instanceof Stage) {
        Stage s=(Stage)graphicsComponent;
        Node root=s.getScene().getRoot();
        startpoint=(root != null) ? getLocation(root,null) : new Point(Rounding.round(s.getWidth() / 2),Rounding.round(s.getHeight() / 2));
      }
 else {
        Node node=(Node)graphicsComponent;
        Node root=node.getScene().getRoot();
        Node c=(root != null) ? root : node;
        startpoint=getLocation(c,null);
      }
    }
    IRobotEventConfirmer confirmer=null;
    InterceptorOptions options=new InterceptorOptions(new long[]{AWTEvent.MOUSE_MOTION_EVENT_MASK});
    if (DragAndDropHelper.getInstance().isDragMode()) {
      confirmer=m_interceptor.intercept(options);
    }
    final Point[] mouseMove=MouseMovementStrategy.getMovementPath(startpoint,p,clickOptions.getStepMovement(),clickOptions.getFirstHorizontal());
    Point currP=new Point(0,0);
    for (int i=0; i < mouseMove.length - 1; i++) {
      m_robot.mouseMove(mouseMove[i].x,mouseMove[i].y);
      currP.x=mouseMove[i].x;
      currP.y=mouseMove[i].y;
      if (!currP.equals(MouseInfo.getPointerInfo().getLocation())) {
        mouseMoveFallback(currP);
      }
    }
    if (!DragAndDropHelper.getInstance().isDragMode()) {
      confirmer=m_interceptor.intercept(options);
    }
    m_robot.mouseMove(mouseMove[mouseMove.length - 1].x,mouseMove[mouseMove.length - 1].y);
    currP.x=mouseMove[mouseMove.length - 1].x;
    currP.y=mouseMove[mouseMove.length - 1].y;
    if (!currP.equals(MouseInfo.getPointerInfo().getLocation())) {
      mouseMoveFallback(currP);
    }
    if (confirmer != null) {
      confirmMove(confirmer,graphicsComponent);
    }
  }
}