replacing assertEquals into assertEqual
[nepi.git] / test / util / sshfuncs.py
index 2c9c30b..ba738b1 100755 (executable)
@@ -178,7 +178,7 @@ class SSHfuncsTestCase(unittest.TestCase):
         (outremote, errrmote), premote = rexec(command, host, user, 
                 port = env.port, agent = True)
 
-        self.assertEquals(outlocal, outremote)
+        self.assertEqual(outlocal, outremote)
 
     def test_rcopy_list(self):
         env = test_environment()
@@ -204,9 +204,9 @@ class SSHfuncsTestCase(unittest.TestCase):
             files.extend(names)
         os.path.walk(destdir, recls, files)
         
-        origfiles = map(lambda s: os.path.basename(s), [dirpath, f.name, f1.name])
+        origfiles = [os.path.basename(s) for s in [dirpath, f.name, f1.name]]
 
-        self.assertEquals(sorted(origfiles), sorted(files))
+        self.assertEqual(sorted(origfiles), sorted(files))
 
         os.remove(f1.name)
         shutil.rmtree(dirpath)
@@ -236,9 +236,9 @@ class SSHfuncsTestCase(unittest.TestCase):
             files.extend(names)
         os.path.walk(destdir, recls, files)
        
-        origfiles = map(lambda s: os.path.basename(s), [dirpath, f.name, f1.name])
+        origfiles = [os.path.basename(s) for s in [dirpath, f.name, f1.name]]
 
-        self.assertEquals(sorted(origfiles), sorted(files))
+        self.assertEqual(sorted(origfiles), sorted(files))
 
     def test_rproc_manage(self):
         env = test_environment()
@@ -271,7 +271,7 @@ class SSHfuncsTestCase(unittest.TestCase):
                 port = env.port, 
                 agent = True)
 
-        self.assertEquals(status, ProcStatus.RUNNING)
+        self.assertEqual(status, ProcStatus.RUNNING)
 
         rkill(pid, ppid,
                 host = host,
@@ -285,7 +285,7 @@ class SSHfuncsTestCase(unittest.TestCase):
                 port = env.port, 
                 agent = True)
         
-        self.assertEquals(status, ProcStatus.FINISHED)
+        self.assertEqual(status, ProcStatus.FINISHED)
 
 
 if __name__ == '__main__':