public void ClickOnAssignmentButton() throws InterruptedException{
System.out.println(eachAssignmentSegment.size());
int SizeOFSegments=eachAssignmentSegment.size();
for(int i=0; i<=SizeOFSegments; i++)
{
if(AssignIcon.get(0).isDisplayed())
{
AssignIcon.get(0).click();
Thread.sleep(2000);
}
else
{
CommonUtils CommonObj=new CommonUtils(driver);
CommonObj.swipingVertical("Bottom2Top");
}
}
}
this is the code
24
FAILED: verifyAssignment
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.rangeCheck(ArrayList.java:635)