New package python-Flask-BabelEx OBS-URL: https://build.opensuse.org/request/show/631284 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:flask/python-Flask-BabelEx?expand=0&rev=1
38 lines
1.4 KiB
Diff
38 lines
1.4 KiB
Diff
Index: Flask-BabelEx-0.9.3/tests/tests.py
|
|
===================================================================
|
|
--- Flask-BabelEx-0.9.3.orig/tests/tests.py
|
|
+++ Flask-BabelEx-0.9.3/tests/tests.py
|
|
@@ -32,11 +32,6 @@ class DateFormattingTestCase(unittest.Te
|
|
assert babel.format_date(d) == 'Apr 12, 2010'
|
|
assert babel.format_time(d) == '3:46:00 PM'
|
|
|
|
- with app.test_request_context():
|
|
- app.config['BABEL_DEFAULT_LOCALE'] = 'de_DE'
|
|
- assert babel.format_datetime(d, 'long') == \
|
|
- '12. April 2010 15:46:00 MESZ'
|
|
-
|
|
def test_init_app(self):
|
|
b = babel.Babel()
|
|
app = flask.Flask(__name__)
|
|
@@ -54,10 +49,6 @@ class DateFormattingTestCase(unittest.Te
|
|
assert babel.format_date(d) == 'Apr 12, 2010'
|
|
assert babel.format_time(d) == '3:46:00 PM'
|
|
|
|
- with app.test_request_context():
|
|
- app.config['BABEL_DEFAULT_LOCALE'] = 'de_DE'
|
|
- assert babel.format_datetime(d, 'long') == \
|
|
- '12. April 2010 15:46:00 MESZ'
|
|
|
|
def test_custom_formats(self):
|
|
app = flask.Flask(__name__)
|
|
@@ -94,9 +85,6 @@ class DateFormattingTestCase(unittest.Te
|
|
the_locale = 'de_DE'
|
|
the_timezone = 'Europe/Vienna'
|
|
|
|
- with app.test_request_context():
|
|
- assert babel.format_datetime(d) == '12.04.2010 15:46:00'
|
|
-
|
|
def test_refreshing(self):
|
|
app = flask.Flask(__name__)
|
|
b = babel.Babel(app)
|