Skip to content

Commit d23c804

Browse files
committed
tests: use assertEqual() inplace assertEquals()
1 parent 3095597 commit d23c804

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

schema_salad/tests/test_examples.py

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def test_schemas(self):
4949
# "edam:has_format": "edam:format_1915"
5050
# }, "")
5151

52-
# self.assertEquals(ra, {
52+
# self.assertEqual(ra, {
5353
# "$schemas": ["tests/EDAM.owl"],
5454
# "$namespaces": {"edam": "http://edamontology.org/"},
5555
# 'http://edamontology.org/has_format': 'http://edamontology.org/format_1915'
@@ -114,12 +114,12 @@ def test_idmap(self):
114114
self.assertEqual("http://example2.com/#stuff", ra["id"])
115115
for item in ra["inputs"]:
116116
if item["a"] == 2:
117-
self.assertEquals(
117+
self.assertEqual(
118118
'http://example2.com/#stuff/zing', item["id"])
119119
else:
120-
self.assertEquals('http://example2.com/#stuff/zip', item["id"])
121-
self.assertEquals(['http://example2.com/#stuff/out'], ra['outputs'])
122-
self.assertEquals({'n': 9}, ra['other'])
120+
self.assertEqual('http://example2.com/#stuff/zip', item["id"])
121+
self.assertEqual(['http://example2.com/#stuff/out'], ra['outputs'])
122+
self.assertEqual({'n': 9}, ra['other'])
123123

124124
def test_scoped_ref(self):
125125
ldr = schema_salad.ref_resolver.Loader({})
@@ -183,7 +183,7 @@ def test_scoped_ref(self):
183183
}
184184
}), "http://example2.com/")
185185

186-
self.assertEquals(
186+
self.assertEqual(
187187
{'inputs': [{
188188
'id': 'http://example2.com/#inp',
189189
'type': 'string'
@@ -362,16 +362,16 @@ def test_mixin(self):
362362
def test_fragment(self):
363363
ldr = schema_salad.ref_resolver.Loader({"id": "@id"})
364364
b, _ = ldr.resolve_ref(get_data("tests/frag.yml#foo2"))
365-
self.assertEquals({"id": b["id"], "bar":"b2"}, b)
365+
self.assertEqual({"id": b["id"], "bar":"b2"}, b)
366366

367367
def test_file_uri(self):
368368
# Note: this test probably won't pass on Windows. Someone with a
369369
# windows box should add an alternate test.
370-
self.assertEquals("file:///foo/bar%20baz/quux", schema_salad.ref_resolver.file_uri("/foo/bar baz/quux"))
371-
self.assertEquals("/foo/bar baz/quux", schema_salad.ref_resolver.uri_file_path("file:///foo/bar%20baz/quux"))
372-
self.assertEquals("file:///foo/bar%20baz/quux%23zing%20zong", schema_salad.ref_resolver.file_uri("/foo/bar baz/quux#zing zong"))
373-
self.assertEquals("file:///foo/bar%20baz/quux#zing%20zong", schema_salad.ref_resolver.file_uri("/foo/bar baz/quux#zing zong", split_frag=True))
374-
self.assertEquals("/foo/bar baz/quux#zing zong", schema_salad.ref_resolver.uri_file_path("file:///foo/bar%20baz/quux#zing%20zong"))
370+
self.assertEqual("file:///foo/bar%20baz/quux", schema_salad.ref_resolver.file_uri("/foo/bar baz/quux"))
371+
self.assertEqual("/foo/bar baz/quux", schema_salad.ref_resolver.uri_file_path("file:///foo/bar%20baz/quux"))
372+
self.assertEqual("file:///foo/bar%20baz/quux%23zing%20zong", schema_salad.ref_resolver.file_uri("/foo/bar baz/quux#zing zong"))
373+
self.assertEqual("file:///foo/bar%20baz/quux#zing%20zong", schema_salad.ref_resolver.file_uri("/foo/bar baz/quux#zing zong", split_frag=True))
374+
self.assertEqual("/foo/bar baz/quux#zing zong", schema_salad.ref_resolver.uri_file_path("file:///foo/bar%20baz/quux#zing%20zong"))
375375

376376

377377
if __name__ == '__main__':

0 commit comments

Comments
 (0)