  
  from django.db import transaction, IntegrityError
  from django.test import TestCase
  
  from .models import (Place, Restaurant, Bar, Waiter, ManualPrimaryKey, RelatedModel,
      MultiModel)
  
  
  class OneToOneTests(TestCase):
  
      def setUp(self):
 
</s> remove from django.db import transaction, IntegrityError
 </s> add from django.db import transaction, IntegrityError, connection </s> remove         self.p1 = Place(name='Demon Dogs', address='944 W. Fullerton')
        self.p1.save()
        self.p2 = Place(name='Ace Hardware', address='1013 N. Ashland')
        self.p2.save()
        self.r = Restaurant(place=self.p1, serves_hot_dogs=True, serves_pizza=False)
        self.r.save()
 </s> add         self.p1 = Place.objects.create(name='Demon Dogs', address='944 W. Fullerton')
        self.p2 = Place.objects.create(name='Ace Hardware', address='1013 N. Ashland')
        self.r1 = Restaurant.objects.create(place=self.p1, serves_hot_dogs=True, serves_pizza=False)
        self.b1 = Bar.objects.create(place=self.p1, serves_cocktails=False) </s> remove         self.r.place = self.p2
        self.r.save()
 </s> add         self.r1.place = self.p2
        self.r1.save()
from .models import (Bar, Favorites, HiddenPointer, ManualPrimaryKey, MultiModel,
    Place, RelatedModel, Restaurant, Target, UndergroundBar, Waiter)
  
  from django.db import transaction, IntegrityError
  from django.test import TestCase
  
from .models import (Bar, Favorites, HiddenPointer, ManualPrimaryKey, MultiModel,
    Place, RelatedModel, Restaurant, Target, UndergroundBar, Waiter)
from .models import (Bar, Favorites, HiddenPointer, ManualPrimaryKey, MultiModel,
    Place, RelatedModel, Restaurant, Target, UndergroundBar, Waiter)
  
  
  class OneToOneTests(TestCase):
  
      def setUp(self):
keep keep keep keep replace replace keep keep keep keep keep
 Merged one_to_one_regress into the one_to_one test package. 
tests/one_to_one/tests.py