diff options
author | Monty Taylor <mordred@inaugust.com> | 2013-05-21 16:54:51 -0400 |
---|---|---|
committer | Monty Taylor <mordred@inaugust.com> | 2013-05-21 16:59:38 -0400 |
commit | 24bd40737ac97ad32226fbd29b50fda05de00364 (patch) | |
tree | 9e5f508133be95fe69ff39a5a5b723021139e5a8 /mox3/tests | |
parent | de1221109c28331684ed4d56913ee6d7541b0cc1 (diff) | |
download | pymox-24bd40737ac97ad32226fbd29b50fda05de00364.tar.gz |
Updated to use OpenStack standards.
Diffstat (limited to 'mox3/tests')
-rw-r--r-- | mox3/tests/mox_helper.py | 6 | ||||
-rw-r--r-- | mox3/tests/test_mox.py (renamed from mox3/tests/mox_test.py) | 9 | ||||
-rw-r--r-- | mox3/tests/test_stubout.py (renamed from mox3/tests/stubout_test.py) | 1 |
3 files changed, 7 insertions, 9 deletions
diff --git a/mox3/tests/mox_helper.py b/mox3/tests/mox_helper.py index ca990c1..4191ba6 100644 --- a/mox3/tests/mox_helper.py +++ b/mox3/tests/mox_helper.py @@ -16,15 +16,15 @@ # This is a fork of the pymox library intended to work with Python 3. # The file was modified by quermit@gmail.com and dawid.fatyga@gmail.com -"""A very basic test class derived from mox.MoxTestBase, used by mox_test.py. +"""A very basic test class derived from mox.MoxTestBase, used by test_mox.py. The class defined in this module is used to test the features of MoxTestBase and is not intended to be a standalone test. It needs to be in a separate module, because otherwise the tests in this class (which should not all pass) would be executed as part of the -mox_test.py test suite. +test_mox.py test suite. -See mox_test.MoxTestBaseTest for how this class is actually used. +See test_mox.MoxTestBaseTest for how this class is actually used. """ import os diff --git a/mox3/tests/mox_test.py b/mox3/tests/test_mox.py index 990d9a3..a331f3d 100644 --- a/mox3/tests/mox_test.py +++ b/mox3/tests/test_mox.py @@ -14,7 +14,6 @@ # See the License for the specific language governing permissions and # limitations under the License. # -# # This is a fork of the pymox library intended to work with Python 3. # The file was modified by quermit@gmail.com and dawid.fatyga@gmail.com @@ -97,13 +96,13 @@ class AndTest(unittest.TestCase): """ test_dict = {"mock": "obj", "testing": "isCOOL"} self.assertTrue(mox.And(mox.In("testing"), - mox.ContainsKeyValue("mock", "obj")) == test_dict) + mox.ContainsKeyValue("mock", "obj")) == test_dict) def testAdvancedUsageFails(self): """Note: this test is reliant on In and ContainsKeyValue.""" test_dict = {"mock": "obj", "testing": "isCOOL"} self.assertFalse(mox.And(mox.In("NOTFOUND"), - mox.ContainsKeyValue("mock", "obj")) == test_dict) + mox.ContainsKeyValue("mock", "obj")) == test_dict) class FuncTest(unittest.TestCase): @@ -2275,8 +2274,8 @@ class MoxTestBaseMultipleInheritanceTest(mox.MoxTestBase, MyTestCase): class MoxTestDontMockProperties(MoxTestBaseTest): def testPropertiesArentMocked(self): mock_class = self.mox.CreateMock(ClassWithProperties) - self.assertRaises(mox.UnknownMethodCallError, lambda: - mock_class.prop_attr) + self.assertRaises(mox.UnknownMethodCallError, + lambda: mock_class.prop_attr) class TestClass(object): diff --git a/mox3/tests/stubout_test.py b/mox3/tests/test_stubout.py index 3426537..be9a94c 100644 --- a/mox3/tests/stubout_test.py +++ b/mox3/tests/test_stubout.py @@ -12,7 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. # -# # This is a fork of the pymox library intended to work with Python 3. # The file was modified by quermit@gmail.com and dawid.fatyga@gmail.com |