def test_generate_dependencies(self):
    models = self.introspector.generate_models(table_names=['tweet'])
    self.assertEqual(set(models), set(('users', 'tweet')))
    IUser = models['users']
    ITweet = models['tweet']
    self.assertEqual(set(ITweet._meta.fields), set(('id', 'user', 'content', 'timestamp')))
    self.assertEqual(set(IUser._meta.fields), set(('id', 'username')))
    self.assertTrue((ITweet.user.rel_model is IUser))
    self.assertTrue((ITweet.user.rel_field is IUser.id))
def test_generate_dependencies(self):
    models = self.introspector.generate_models(table_names=['tweet'])
    self.assertEqual(set(models), set(('users', 'tweet')))
    IUser = models['users']
    ITweet = models['tweet']
    self.assertEqual(set(ITweet._meta.fields), set(('id', 'user', 'content', 'timestamp')))
    self.assertEqual(set(IUser._meta.fields), set(('id', 'username')))
    self.assertTrue((ITweet.user.rel_model is IUser))
    self.assertTrue((ITweet.user.rel_field is IUser.id))