mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Fixes #3721: Allow Unicode characters in tag slugs
This commit is contained in:
@@ -3,7 +3,7 @@ from django.test import TestCase
|
||||
|
||||
from dcim.models import Site
|
||||
from extras.choices import TemplateLanguageChoices
|
||||
from extras.models import Graph
|
||||
from extras.models import Graph, Tag
|
||||
|
||||
|
||||
class GraphTest(TestCase):
|
||||
@@ -44,3 +44,12 @@ class GraphTest(TestCase):
|
||||
|
||||
self.assertEqual(graph.embed_url(self.site), RENDERED_TEXT)
|
||||
self.assertEqual(graph.embed_link(self.site), RENDERED_TEXT)
|
||||
|
||||
|
||||
class TagTest(TestCase):
|
||||
|
||||
def test_create_tag_unicode(self):
|
||||
tag = Tag(name='Testing Unicode: 台灣')
|
||||
tag.save()
|
||||
|
||||
self.assertEqual(tag.slug, 'testing-unicode-台灣')
|
||||
|
Reference in New Issue
Block a user