Fix #190 and #472 -- Change of questions within pretix control

This commit is contained in:
Raphael Michel
2018-01-26 12:43:47 +01:00
parent 083c94403b
commit 1ee6e31538
19 changed files with 732 additions and 546 deletions

View File

@@ -0,0 +1,15 @@
from pretix.base.i18n import language
from pretix.helpers.i18n import get_javascript_format, get_moment_locale
def test_js_formats():
with language('de'):
assert get_javascript_format('DATETIME_INPUT_FORMATS') == 'DD.MM.YYYY HH:mm:ss'
with language('en'):
assert get_javascript_format('DATETIME_INPUT_FORMATS') == 'YYYY-MM-DD HH:mm:ss'
def test_get_locale():
get_moment_locale('af') == 'af'
get_moment_locale('de_Informal') == 'de'
get_moment_locale('de-AT') == 'de'