Ionel Maries Cristian avatar Ionel Maries Cristian committed e1fc25a

Remove InheritedFieldSyncFlagTest and associated models.

Comments (0)

Files changed (2)

tests/test_project/apps/testapp/models.py

     cmtm_a = cachedmtmfield.CachedManyToManyField(TestModelA)
     cmtm_b = cachedmtmfield.CachedManyToManyField(TestModelB)
     
-from dcfields.inheritedfield import InheritedField
-
-class TestModelParent(models.Model):
-    title = models.CharField(max_length=255)
-
-class TestModelChild(models.Model):
-    parent = models.ForeignKey(TestModelParent)
-    title = InheritedField('parent', sync=True)
-
-    
-##############################333
-
-
 class Stuff(models.Model):
     pass
 

tests/test_project/apps/testapp/tests.py

         c.save()
         self.assertRaises(TypeError, lambda: TestModelC.objects.filter(cmtm_a_cache=1))
 
-
-#class InheritedFieldSyncFlagTest(TestCase):
-#    def setUp(self):
-#        self.parent = TestModelParent.objects.create(title='Parent')
-#        self.child = TestModelChild.objects.create(parent=self.parent)
-#    
-#    # presave not implemented yet
-#    def test_inheritance_simple(self):
-#        self.assertEquals(self.parent.title, 'Parent')
-#        self.assertEquals(self.child.is_title_inherited, True)
-#        self.assertEquals(self.child.title, 'Parent')
-#
-#    def test_local_value(self):
-#        self.child.title = 'Child'
-#        self.assertEquals(self.child.is_title_inherited, False)
-#        self.assertEquals(self.child.title, 'Child')
-#        self.assertEquals(self.parent.title, 'Parent')
-#
-#    def test_parent_update_inherited(self):
-#        self.parent.title = 'Parent 1'
-#        self.assertEquals(self.parent.title, 'Parent 1')
-#        self.assertEquals(self.child.title, 'Parent 1')
-#
-#    def test_parent_update_not_inherited(self):
-#        self.child.title = 'Child'
-#        self.parent.title = 'Parent 1'
-#
-#        self.assertEquals(self.parent.title, 'Parent 1')
-#        self.assertEquals(self.child.title, 'Child')
-#        self.assertEquals(self.child.is_title_inherited, False)
-#
-#    def test_restore_inherited_flag(self):
-#        self.child.title = 'Child'
-#        self.parent.title = 'Parent 1'
-#        self.child.title_inherited = True
-#        self.assertEquals(self.child.title, 'Parent 1')
-
-
 class InheritedFieldTests(TestCase):
     def test_model_field_inheritance_broken_parent(self):
         b = TestModel2()
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.