title: Android Robotium - ViewPager swipe is not working
body: <p>I wants to swipe the ViewPager. I used following code for page swipe. But unfortunately is not working.</p>
  
  <pre><code>Solo solo = new Solo(getInstrumentation(), getActivity());    
              int screenHeight = activityUtils.getCurrentActivity().getWindowManager().getDefaultDisplay()
                      .getHeight();
              int screenWidth = activityUtils.getCurrentActivity(false).getWindowManager().getDefaultDisplay()
                      .getWidth();
              float x = screenWidth / 3.0f * 2.0f;
              float y = screenHeight / 3.0f * 2.0f;
  </code></pre>
  
  <p><strong>Try: 1</strong></p>
  
  <pre><code>solo.swipe(x, 0, y, y, 40);
  </code></pre>
  
  <p><strong>Try: 2</strong></p>
  
  <pre><code>if (side == Side.LEFT)
      drag(0, x, y, y, 40);
  else if (side == Side.RIGHT)
      drag(x, 0, y, y, 40);
  </code></pre>
  
  <p><strong>Try: 3</strong> 
  Following method working but it's moving only single page and also it's moving very slowly.</p>
  
  <pre><code> solo1.scrollToSide(Solo.RIGHT); 
  </code></pre>
  
  <p>Is there any option for fast swipe? Which one is best? Kindly share your ideas.</p>
  
  <p><strong>My code with Robotium 5.1</strong></p>
  
  <pre><code>for (int count = 0; count &lt; noOfPages; count++)
     solo.swipeToRight(count);
  </code></pre>
  
  <p><strong>Methods for view pager swipes</strong></p>
  
  <pre><code>private void swipeToLeft(int stepCount) {
      Display display = solo.getCurrentActivity().getWindowManager().getDefaultDisplay();
      int width = display.getWidth();
      int height = display.getHeight();
      float xStart = width - 10 ;
      float xEnd = 10;
      solo.drag(xStart, xEnd, height / 2, height / 2, stepCount);
  }
  
  private void swipeToRight(int stepCount) {
      Display display = solo.getCurrentActivity().getWindowManager().getDefaultDisplay();
      int width = display.getWidth();
      int height = display.getHeight();
      float xStart = 10 ;
      float xEnd = width - 10;
      solo.drag(xStart, xEnd, height / 2, height / 2, stepCount);
  }
  </code></pre>