def METHOD_NAME(self):
    self.xform.shared = True
    self.xform.save()
    response = self.client.post(self.edit_url, {'toggle_shared': 'form'},
                                HTTP_X_REQUESTED_WITH='XMLHttpRequest')
    self.assertEqual(response.status_code, 200)
    self.assertEqual(XForm.objects.get(pk=self.xform.pk).shared, False)