mirror of
https://github.com/simon987/nyaa.git
synced 2025-12-14 07:39:03 +00:00
Move template filters and globals into blueprint (#301)
* Move 8 of 9 template filters and globals into a blueprint * Rename nyaa.filters -> nyaa.template_utils * Fix import sorting
This commit is contained in:
@@ -4,11 +4,12 @@ import datetime
|
||||
from email.utils import formatdate
|
||||
|
||||
from tests import NyaaTestCase
|
||||
from nyaa.routes import (_jinja2_filter_rfc822, _jinja2_filter_rfc822_es, get_utc_timestamp,
|
||||
get_display_time, timesince, filter_truthy, category_name)
|
||||
from nyaa.routes import category_name
|
||||
from nyaa.template_utils import (_jinja2_filter_rfc822, _jinja2_filter_rfc822_es, get_utc_timestamp,
|
||||
get_display_time, timesince, filter_truthy)
|
||||
|
||||
|
||||
class TestFilters(NyaaTestCase):
|
||||
class TestTemplateUtils(NyaaTestCase):
|
||||
|
||||
# def setUp(self):
|
||||
# self.db, nyaa.app.config['DATABASE'] = tempfile.mkstemp()
|
||||
Reference in New Issue
Block a user