1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
|
From: Paul Zander <negril.nx+gentoo@gmail.com>
tests: use assertEqual instead of assertEquals
tests: use assertRaises instead of failUnlessRaises
diff --git a/python/PyAlembic/Tests/testCollections.py b/python/PyAlembic/Tests/testCollections.py
index ab48a54..1745582 100644
--- a/python/PyAlembic/Tests/testCollections.py
+++ b/python/PyAlembic/Tests/testCollections.py
@@ -67,14 +67,14 @@ class CollectionTest(unittest.TestCase):
prop = group.getSchema().createCollection("prop")
prop.setValue(strVec)
- self.assertEquals(group.getSchema().getNumCollections(), 1)
+ self.assertEqual(group.getSchema().getNumCollections(), 1)
# TODO passing in time sampling here causes a segfault, most likely because
# of how createCollection currently takes an Argument &, see #274
cool = group.getSchema().createCollection("cool", md)
cool.setTimeSampling(ts)
- self.assertEquals(
+ self.assertEqual(
group.getSchema().getCollection(1).getMetaData().get("coupe"),
"de ville" )
diff --git a/python/PyAlembic/Tests/testCurves.py b/python/PyAlembic/Tests/testCurves.py
index dba9e1c..956625a 100644
--- a/python/PyAlembic/Tests/testCurves.py
+++ b/python/PyAlembic/Tests/testCurves.py
@@ -59,7 +59,7 @@ class CurvesTest(unittest.TestCase):
widthSamp, uvSamp )
knots = curvesSamp.getKnots()
- self.assertEquals(len(knots), 0)
+ self.assertEqual(len(knots), 0)
newKnots = FloatArray(4)
for ii in range(4):
diff --git a/python/PyAlembic/Tests/testTypes.py b/python/PyAlembic/Tests/testTypes.py
index bad9577..f0e8d26 100644
--- a/python/PyAlembic/Tests/testTypes.py
+++ b/python/PyAlembic/Tests/testTypes.py
@@ -60,7 +60,7 @@ class TypesTest(unittest.TestCase):
self.assertIsNotNone(POD.kUnknownPOD)
# If a new POD type is added, this will throw an exception
- self.assertEquals(POD.kNumPlainOldDataTypes, 14)
+ self.assertEqual(POD.kNumPlainOldDataTypes, 14)
def testDataTypeWrapper(self):
# Default Constructor
diff --git a/maya/Tests/AbcExport_dupRoots_test.py b/maya/Tests/AbcExport_dupRoots_test.py
index d532c10..f864281 100644
--- a/maya/Tests/AbcExport_dupRoots_test.py
+++ b/maya/Tests/AbcExport_dupRoots_test.py
@@ -48,7 +48,7 @@ class AbcExport_dupRootsTest(unittest.TestCase):
MayaCmds.group(n='group1')
MayaCmds.duplicate()
- self.failUnlessRaises(RuntimeError, MayaCmds.AbcExport,
+ self.assertRaises(RuntimeError, MayaCmds.AbcExport,
j='-root group1|cube -root group2|cube -f dupRoots.abc')
# the abc file shouldn't exist
diff --git a/python/PyAlembic/Tests/testPropExcept.py b/python/PyAlembic/Tests/testPropExcept.py
index e1a1dff..2ddf40d 100644
--- a/python/PyAlembic/Tests/testPropExcept.py
+++ b/python/PyAlembic/Tests/testPropExcept.py
@@ -70,5 +70,5 @@ class PropExceptTest(unittest.TestCase):
p = props.getProperty("myprop")
self.assertEqual(p.getName(), "myprop")
- self.failUnlessRaises(KeyError, props.getProperty, "notfound")
+ self.assertRaises(KeyError, props.getProperty, "notfound")
self.assertRaises(IndexError, props.getProperty, 99)
|