'M2M relations are represented by managers, and can be controlled like managers'

def test_m2m_managers(self):

    pro = Book.objects.using(u'other').create(pk=1, title=u'Pro    Django', published=datetime.date(2008, 12, 16))
    marty = Person.objects.using(u'other').create(pk=1, name=u'Marty    Alchin')
    pro_authors = pro.authors.using(u'other')
    authors = [marty]
    self.assertEqual(pro.authors.db, u'other')
    self.assertEqual(pro.authors.db_manager(u'default').db, u'default')
    self.assertEqual(pro.authors.db_manager(u'default').all().db, u'default')
    self.assertEqual(marty.book_set.db, u'other')
    self.assertEqual(marty.book_set.db_manager(u'default').db, u'default')
    self.assertEqual(marty.book_set.db_manager(u'default').all().db, u'default')
