mrunit-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gortiz <gor...@pragsis.com>
Subject Trying to use MRUnit with MultipleOutput
Date Mon, 13 Oct 2014 13:14:04 GMT
I'm trying to test some MapReduces with MRUnit 1.1.0, but I got this error:

     14/10/13 14:19:49 ERROR mrunit.TestDriver: Missing expected outputs 
for namedOutput 'a'
     14/10/13 14:19:49 ERROR mrunit.TestDriver: Missing expected output 
(b, a) for namedOutput 'a' at position 0.
     14/10/13 14:19:49 ERROR mrunit.TestDriver: Expected no pathOutputs; 
got 1 pathOutputs.
     14/10/13 14:19:49 ERROR mrunit.TestDriver: Received unexpected 
output (b, a) for unexpected PathOutput 'a'

   The code that I execute is:

     mapTextDriver.withInput(new LongWritable(1), new Text(content));
     mapTextDriver.withMultiOutput("a", "b", "a");
     mapTextDriver.runTest();

I was reading the JIRA https://issues.apache.org/jira/browse/MRUNIT-13 
where they add the new feature to MRUnit but I don't know what I'm missing..

I included as well the annotations:

     @RunWith(..)
     @PrepareForTest(..)

I tried as well to execute the test like:
     List<Pair<NullWritable, Text>> outputs = mapTextDriver.run();

But, I never got an output,  the  list has always size of 0.

AVISO CONFIDENCIAL\nEste correo y la información contenida o adjunta al mismo es privada
y confidencial y va dirigida exclusivamente a su destinatario. Pragsis informa a quien pueda
haber recibido este correo por error que contiene información confidencial cuyo uso, copia,
reproducción o distribución está expresamente prohibida. Si no es Vd. el destinatario del
mismo y recibe este correo por error, le rogamos lo ponga en conocimiento del emisor y proceda
a su eliminación sin copiarlo, imprimirlo o utilizarlo de ningún modo.\nCONFIDENTIALITY
WARNING.\nThis message and the information contained in or attached to it are private and
confidential and intended exclusively for the addressee. Pragsis informs to whom it may receive
it in error that it contains privileged information and its use, copy, reproduction or distribution
is prohibited. If you are not an intended recipient of this E-mail, please notify the sender,
delete it and do not read, act upon, print, disclose, copy, reta
 in or redistribute any portion of this E-mail.

Mime
View raw message