added test of matrixIterator