e7230b7391
* seperate unittests and integration tests * moved old tests in seperat folder 'old' * created a testrunner that does not create a testdatabase, if only unittests are run * wrote some unit- and integration tests as examples * fixed user.get_short_name() to use the sort order from config * fixed wrong url_pattern in the user app
13 lines
424 B
Python
13 lines
424 B
Python
from types import GeneratorType
|
|
from unittest.mock import MagicMock
|
|
|
|
from openslides.utils.forms import LocalizedModelMultipleChoiceField
|
|
from openslides.utils.test import TestCase
|
|
|
|
|
|
class TestLocalizedModelMultipleChoiceField(TestCase):
|
|
def test_localized_get_choices(self):
|
|
test_field = LocalizedModelMultipleChoiceField(queryset=MagicMock())
|
|
|
|
self.assertEqual(type(test_field.choices), GeneratorType)
|