java.lang.IndexOutOfBoundsException at AlphavantageServiceTest

This error is really frustrating i have check my code even getting value after debugging but dont know why this error keep on popping again and again whenever i am running this command

./gradlew test --tests AlphavantageServiceTest

stuck on this from 2 days.

Make sure that you have properly instantiated Arraylist
(like List<> list = new ArrayList<>()) something like this.

yes i have properly instantiated Arraylist.
@Sammed

when you debug you can actually see the contents of List in variables tab to the left try to check if there are elements in list

@Sammed
yes i can see the contents in list and i have checked it its working normally.

finally solved the issue i was using isBefore() and isEqual() method change those method and use different approach and issue solved.

1 Like

Well done! Seems like we have solution for this query, Ill be closing this ticket. If you face any problem in future, feel free to raise a new query.