accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject svn commit: r1326602 - /accumulo/trunk/test/system/auto/simple/mapreduce.py
Date Mon, 16 Apr 2012 13:17:35 GMT
Author: ecn
Date: Mon Apr 16 13:17:34 2012
New Revision: 1326602

URL: http://svn.apache.org/viewvc?rev=1326602&view=rev
Log:
ACCUMULO-539 stop using the md5 module

Modified:
    accumulo/trunk/test/system/auto/simple/mapreduce.py

Modified: accumulo/trunk/test/system/auto/simple/mapreduce.py
URL: http://svn.apache.org/viewvc/accumulo/trunk/test/system/auto/simple/mapreduce.py?rev=1326602&r1=1326601&r2=1326602&view=diff
==============================================================================
--- accumulo/trunk/test/system/auto/simple/mapreduce.py (original)
+++ accumulo/trunk/test/system/auto/simple/mapreduce.py Mon Apr 16 13:17:34 2012
@@ -20,7 +20,7 @@ import unittest
 import time
 import sys
 import subprocess
-import md5
+import hashlib
 import base64
 import re
 import glob
@@ -116,7 +116,7 @@ class MapReduceTest(TestUtilsMixin,unitt
         return val_list
     
     def checkResults(self):
-        control_values = [base64.b64encode(md5.new("row%s"%(i)).digest()) for i in range(10)]
+        control_values = [base64.b64encode(hashlib.md5("row%s"%(i)).digest()) for i in range(10)]
         experiment_values = self.retrieveValues(self.output_tablename, self.output_cfcq)
         self.failIf(len(control_values) != len(experiment_values), "List aren't the same
length")
         diff=[ev for ev in experiment_values if ev not in control_values]
@@ -124,7 +124,7 @@ class MapReduceTest(TestUtilsMixin,unitt
     
     def fakeMRResults(self):
         vals = self.retrieveValues(self.input_tablename, self.input_cfcq)
-        values = ["insert %s %s %s\n" % (i,self.output_cfcq.replace(":"," "),base64.b64encode(md5.new("row%s"
% i).digest())) for i in range(10,20)]
+        values = ["insert %s %s %s\n" % (i,self.output_cfcq.replace(":"," "),base64.b64encode(hashlib.md5("row%s"
% i).digest())) for i in range(10,20)]
         input = "table %s\n" % (self.input_tablename,)+"".join(values)
         out,err,code = self.rootShell(self.masterHost(),input)
         #print "FAKE",out



Mime
View raw message