// run the job
for (int i = 0; i < MATRIX.length; i++) {
Vector v = new RandomAccessSparseVector(MATRIX[i].length);
v.assign(MATRIX[i]);
mapper.map(new IntWritable(i), new VectorWritable(v), context);
}
// check the results
assertEquals("Number of map results", MATRIX.length, writer.getData().size());
for (int i = 0; i < MATRIX.length; i++) {