Index out of bounds unittest