From 7f8292f39da0221c0c5dbe1f31190f552d6c14d6 Mon Sep 17 00:00:00 2001
From: Christian Berendt <berendt@b1-systems.de>
Date: Thu, 24 Oct 2013 07:54:16 +0200
Subject: [PATCH] change assertEquals to assertEqual

According to http://docs.python.org/2/library/unittest.html
assertEquals is a deprecated alias of assertEqual.

Change-Id: I22f4702f41537c05684dfacb3f305627b36849c5
---
 tests/test_http.py      |  4 ++--
 tests/test_shell.py     |  4 ++--
 tests/v2/test_images.py | 14 +++++++-------
 3 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/tests/test_http.py b/tests/test_http.py
index 8bc262d5..ebc7dee0 100644
--- a/tests/test_http.py
+++ b/tests/test_http.py
@@ -56,7 +56,7 @@ class TestClient(testtools.TestCase):
         kwargs = {'token': u'fake-token',
                   'identity_headers': identity_headers}
         http_client_object = http.HTTPClient(self.endpoint, **kwargs)
-        self.assertEquals(http_client_object.auth_token, 'auth_token')
+        self.assertEqual(http_client_object.auth_token, 'auth_token')
         self.assertTrue(http_client_object.identity_headers.
                         get('X-Auth-Token') is None)
 
@@ -72,7 +72,7 @@ class TestClient(testtools.TestCase):
         kwargs = {'token': u'fake-token',
                   'identity_headers': identity_headers}
         http_client_object = http.HTTPClient(self.endpoint, **kwargs)
-        self.assertEquals(http_client_object.auth_token, u'fake-token')
+        self.assertEqual(http_client_object.auth_token, u'fake-token')
         self.assertTrue(http_client_object.identity_headers.
                         get('X-Auth-Token') is None)
 
diff --git a/tests/test_shell.py b/tests/test_shell.py
index cdbd632a..27b12280 100644
--- a/tests/test_shell.py
+++ b/tests/test_shell.py
@@ -177,7 +177,7 @@ class ShellCacheSchemaTest(utils.TestCase):
 
         self.assertTrue(os.path.exists(cache_file))
         text = self._read_file(cache_file)
-        self.assertEquals(text, json.dumps(self.schema_dict))
+        self.assertEqual(text, json.dumps(self.schema_dict))
 
     def test_cache_schema_leaves_when_present_not_forced(self):
         cache_dir = tempfile.gettempdir()
@@ -199,4 +199,4 @@ class ShellCacheSchemaTest(utils.TestCase):
 
         self.assertTrue(os.path.exists(cache_file))
         text = self._read_file(cache_file)
-        self.assertEquals(text, dummy_schema)
+        self.assertEqual(text, dummy_schema)
diff --git a/tests/v2/test_images.py b/tests/v2/test_images.py
index bc9e1163..afc7f973 100644
--- a/tests/v2/test_images.py
+++ b/tests/v2/test_images.py
@@ -364,7 +364,7 @@ class TestController(testtools.TestCase):
         fake_id = '3a4560a1-e585-443e-9b39-553b46ec92d1'
         filters = {'filters': dict([('checksum', _CHKSUM)])}
         images = list(self.controller.list(**filters))
-        self.assertEquals(1, len(images))
+        self.assertEqual(1, len(images))
         self.assertEqual(images[0].id, '%s' % fake_id)
 
     def test_list_images_for_checksum_multiple_images(self):
@@ -372,14 +372,14 @@ class TestController(testtools.TestCase):
         fake_id2 = '6f99bf80-2ee6-47cf-acfe-1f1fabb7e810'
         filters = {'filters': dict([('checksum', _CHKSUM1)])}
         images = list(self.controller.list(**filters))
-        self.assertEquals(2, len(images))
+        self.assertEqual(2, len(images))
         self.assertEqual(images[0].id, '%s' % fake_id1)
         self.assertEqual(images[1].id, '%s' % fake_id2)
 
     def test_list_images_for_wrong_checksum(self):
         filters = {'filters': dict([('checksum', 'wrong')])}
         images = list(self.controller.list(**filters))
-        self.assertEquals(0, len(images))
+        self.assertEqual(0, len(images))
 
     def test_list_images_for_bogus_owner(self):
         filters = {'filters': dict([('owner', _BOGUS_ID)])}
@@ -410,7 +410,7 @@ class TestController(testtools.TestCase):
         img_id = '3a4560a1-e585-443e-9b39-553b46ec92d1'
         filters = {'filters': dict([('tag', [_TAG1])])}
         images = list(self.controller.list(**filters))
-        self.assertEquals(1, len(images))
+        self.assertEqual(1, len(images))
         self.assertEqual(images[0].id, '%s' % img_id)
         pass
 
@@ -419,7 +419,7 @@ class TestController(testtools.TestCase):
         img_id2 = '6f99bf80-2ee6-47cf-acfe-1f1fabb7e810'
         filters = {'filters': dict([('tag', [_TAG2])])}
         images = list(self.controller.list(**filters))
-        self.assertEquals(2, len(images))
+        self.assertEqual(2, len(images))
         self.assertEqual(images[0].id, '%s' % img_id1)
         self.assertEqual(images[1].id, '%s' % img_id2)
 
@@ -427,13 +427,13 @@ class TestController(testtools.TestCase):
         img_id1 = '2a4560b2-e585-443e-9b39-553b46ec92d1'
         filters = {'filters': dict([('tag', [_TAG1, _TAG2])])}
         images = list(self.controller.list(**filters))
-        self.assertEquals(1, len(images))
+        self.assertEqual(1, len(images))
         self.assertEqual(images[0].id, '%s' % img_id1)
 
     def test_list_images_for_non_existent_tag(self):
         filters = {'filters': dict([('tag', ['fake'])])}
         images = list(self.controller.list(**filters))
-        self.assertEquals(0, len(images))
+        self.assertEqual(0, len(images))
 
     def test_get_image(self):
         image = self.controller.get('3a4560a1-e585-443e-9b39-553b46ec92d1')