'Move a thread.'

def test_move_thread(self):

    t = ThreadFactory()
    f = ForumFactory()
    u = UserFactory()
    g = GroupFactory()
    ct = ContentType.objects.get_for_model(f)
    PermissionFactory(codename='forums_forum.thread_move_forum', content_type=ct, object_id=f.id, group=g)
    PermissionFactory(codename='forums_forum.thread_move_forum', content_type=ct, object_id=t.forum.id, group=g)
    g.user_set.add(u)
    self.client.login(username=u.username, password='testpass')
    response = post(self.client, 'forums.move_thread', {'forum': f.id}, args=[t.forum.slug, t.id])
    eq_(200, response.status_code)
    t = Thread.objects.get(pk=t.pk)
    eq_(f.id, t.forum.id)
