def setUpTestData(cls):

        sites = (
            Site(name='Site 1', slug='site-1'),
            Site(name='Site 2', slug='site-2'),
            Site(name='Site 3', slug='site-3'),
        )
        Site.objects.bulk_create(sites)

        rack_groups = (
            RackGroup(name='Rack Group 1', slug='rack-group-1', site=sites[0]),
            RackGroup(name='Rack Group 2', slug='rack-group-2', site=sites[1]),
            RackGroup(name='Rack Group 3', slug='rack-group-3', site=sites[2]),
        )
        for rackgroup in rack_groups:
            rackgroup.save()

        racks = (
            Rack(name='Rack 1', site=sites[0], group=rack_groups[0]),
            Rack(name='Rack 2', site=sites[1], group=rack_groups[1]),
            Rack(name='Rack 3', site=sites[2], group=rack_groups[2]),
        )
        Rack.objects.bulk_create(racks)

        users = (
            User(username='User 1'),
            User(username='User 2'),
            User(username='User 3'),
        )
        User.objects.bulk_create(users)

        tenant_groups = (
            TenantGroup(name='Tenant group 1', slug='tenant-group-1'),
            TenantGroup(name='Tenant group 2', slug='tenant-group-2'),
            TenantGroup(name='Tenant group 3', slug='tenant-group-3'),
        )
        for tenantgroup in tenant_groups:
            tenantgroup.save()

        tenants = (
            Tenant(name='Tenant 1', slug='tenant-1', group=tenant_groups[0]),
            Tenant(name='Tenant 2', slug='tenant-2', group=tenant_groups[1]),
            Tenant(name='Tenant 3', slug='tenant-3', group=tenant_groups[2]),
        )
        Tenant.objects.bulk_create(tenants)

        reservations = (
            RackReservation(rack=racks[0], units=[1, 2, 3], user=users[0], tenant=tenants[0]),
            RackReservation(rack=racks[1], units=[4, 5, 6], user=users[1], tenant=tenants[1]),
            RackReservation(rack=racks[2], units=[7, 8, 9], user=users[2], tenant=tenants[2]),
        )
        RackReservation.objects.bulk_create(reservations)