Adds a test for non-standard characters via API

This commit is contained in:
Oliver 2021-09-17 20:53:18 +10:00
parent d73a7176fd
commit 11cc0c7ced

View File

@ -588,6 +588,21 @@ class PartAPITest(InvenTreeAPITestCase):
self.assertEqual(new_part.supplier_parts.count(), 1)
self.assertEqual(new_part.manufacturer_parts.count(), 1)
def test_strange_chars(self):
"""
Test that non-standard ASCII chars are accepted
"""
url = reverse('api-part-list')
data = {
"name": "Kaltgerätestecker",
"description": "Gerät",
"category": 2
}
response = self.post(url, data, expected_code=201)
class PartDetailTests(InvenTreeAPITestCase):
"""