def test_reverse_slugs(self): item = models.ObjectClass.objects.create(name=" ",definition="my definition",submitter=None) ra = models.RegistrationAuthority.objects.create(name=" ",definition="my definition") org = models.Organization.objects.create(name=" ",definition="my definition") wg = models.Workgroup.objects.create(name=" ",definition="my definition") self.assertTrue('--' in utils.url_slugify_concept(item)) self.assertTrue('--' in utils.url_slugify_workgroup(wg)) self.assertTrue('--' in utils.url_slugify_registration_authoritity(ra)) self.assertTrue('--' in utils.url_slugify_organization(org))
def get_absolute_url(self): return url_slugify_workgroup(self)