

def test_adding_new_version_reorders(self):
    'Adding a new product version reorders the versions.'
    p = self.F.ProductFactory.create()
    self.F.ProductVersionFactory.create(version='2.11', product=p)
    self.F.ProductVersionFactory.create(version='2.9', product=p)
    v.F.ProductVersionFactory.create(version='2.10', product=p)
    self.assertEqual([(v.version, v.latest) for v in p.versions.all()], [('2.9', False), ('2.10', False), ('2.11', True)])

dataset/ETHPy150Open mozilla/moztrap/tests/model/core/models/test_productversion.py ProductVersionTest.test_adding_new_version_reorders/VarMisuse@58/95 `self`->`v`