← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] lp:~jtv/maas/prep-node-tests into lp:maas

 

Jeroen T. Vermeulen has proposed merging lp:~jtv/maas/prep-node-tests into lp:maas.

Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)

For more details, see:
https://code.launchpad.net/~jtv/maas/prep-node-tests/+merge/110457

As per the migration plan.  But since the Node model is the bulk of our code (and probably of potential merge conflicts as well), the migration will consist of breaking everything else out of the test and renaming test_models.py to test_node.py.  That way bzr will see the node-related test code as unchanged.

You'll notice a comment in a weird place at the top.  That's because our imports-formatting tool and our lint checker have different ideas about how many blank lines are required if the first code after the imports is a module.  Annoying, but in this case the comment will be gone soon enough so I don't much care.


Jeroen
-- 
https://code.launchpad.net/~jtv/maas/prep-node-tests/+merge/110457
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~jtv/maas/prep-node-tests into lp:maas.
=== modified file 'src/maasserver/tests/test_models.py'
--- src/maasserver/tests/test_models.py	2012-06-14 06:53:15 +0000
+++ src/maasserver/tests/test_models.py	2012-06-15 05:33:18 +0000
@@ -69,6 +69,7 @@
 
 
 class UtilitiesTest(TestCase):
+# Scheduled for model migration on 2012-06-21
 
     def test_now_returns_datetime(self):
         self.assertIsInstance(now(), datetime)
@@ -78,6 +79,7 @@
         self.assertEqual(date_now, now())
 
 
+# Scheduled for model migration on 2012-06-21
 class UtilitiesTransactionalTest(TransactionTestCase):
 
     def test_now_returns_transaction_time(self):
@@ -88,6 +90,7 @@
         self.assertLessEqual(date_now, now())
 
 
+# Scheduled for model migration on 2012-06-21
 class TimestampedModelTest(TestModelTestCase):
     """Testing for the class `TimestampedModel`."""
 
@@ -116,6 +119,7 @@
         self.assertEqual(old_created, obj.created)
 
 
+# Scheduled for model migration on 2012-06-21
 class TimestampedModelTransactionalTest(TestModelTransactionalTestCase):
 
     app = 'maasserver.tests'
@@ -514,6 +518,7 @@
         self.assertTrue(set(all_destination_states) <= allowed_states)
 
 
+# Scheduled for model migration on 2012-06-21
 class GetDbStateTest(TestCase):
     """Testing for the method `get_db_state`."""
 
@@ -872,6 +877,7 @@
         self.assertEqual(user_data, NodeUserData.objects.get_user_data(node))
 
 
+# Scheduled for model migration on 2012-06-21
 class MACAddressTest(TestCase):
 
     def make_MAC(self, address):
@@ -889,6 +895,7 @@
         self.assertRaises(ValidationError, mac.full_clean)
 
 
+# Scheduled for model migration on 2012-06-21
 class AuthTokensTest(TestCase):
     """Test creation and retrieval of auth tokens."""