fix invalid array index references in unit test

One of the unit tests was not passing. I changed the array indexers and now all tests pass.