Commit c9a6581c authored by Hermann Krumrey's avatar Hermann Krumrey

Add more convenience features

parent e2737d21
Pipeline #1878 passed with stages
in 3 minutes and 43 seconds
......@@ -6,4 +6,6 @@ cover/
dist/
build/
./secrets.json
.env
\ No newline at end of file
.env
.mypy_cache/
__pycache__/
\ No newline at end of file
V 0.3.2:
- More convenience features
V 0.3.1:
- Removed MYSQL_DATABASE environment variable from docker-compose.yml
V 0.3.0:
......
# fat-ffipd
Flask Application Template - For Fast Initial Project Develoment
Flask Application Template - For Fast Initial Project Development
|master|develop|
|:----:|:-----:|
......
"""LICENSE
Copyright 2020 Hermann Krumrey <hermann@krumreyh.com>
This file is part of fat-ffipd.
fat-ffipd is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
fat-ffipd is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with fat-ffipd. If not, see <http://www.gnu.org/licenses/>.
LICENSE"""
from typing import List
from puffotter.flask.base import db
models: List[db.Model] = [
]
"""
The database models of the application
"""
......@@ -21,8 +21,10 @@ from puffotter.env import load_env_file
from puffotter.flask.initialize import init_flask
from puffotter.flask.wsgi import start_server
from fat_ffipd import sentry_dsn, root_path
from fat_ffipd.bg_tasks import bg_tasks
from fat_ffipd.background import bg_tasks
from fat_ffipd.Config import Config
from fat_ffipd.routes import blueprint_generators
from fat_ffipd.db import models
def main():
......@@ -36,7 +38,7 @@ def main():
sentry_dsn,
root_path,
Config,
[],
[]
models,
blueprint_generators
)
start_server(Config, bg_tasks)
"""LICENSE
Copyright 2020 Hermann Krumrey <hermann@krumreyh.com>
This file is part of fat-ffipd.
fat-ffipd is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
fat-ffipd is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with fat-ffipd. If not, see <http://www.gnu.org/licenses/>.
LICENSE"""
from flask.blueprints import Blueprint
from typing import List, Tuple, Callable
blueprint_generators: List[Tuple[Callable[[str], Blueprint], str]] = [
]
"""
Defines the functions used to create the various blueprints
as well as their names
"""
......@@ -17,10 +17,13 @@ You should have received a copy of the GNU General Public License
along with fat-ffipd. If not, see <http://www.gnu.org/licenses/>.
LICENSE"""
from fat_ffipd.main import root_path
from puffotter.flask.test.TestFramework import \
_TestFramework as __TestFrameWork
# noinspection PyProtectedMember
from puffotter.flask.test.TestFramework import _TestFramework \
as __TestFrameWork
from fat_ffipd import root_path
from fat_ffipd.Config import Config
from fat_ffipd.routes import blueprint_generators
from fat_ffipd.db import models
class _TestFramework(__TestFrameWork):
......@@ -30,3 +33,5 @@ class _TestFramework(__TestFrameWork):
module_name = "fat_ffipd"
root_path = root_path
config = Config
models = models
blueprint_generators = blueprint_generators
......@@ -18,7 +18,7 @@ along with fat-ffipd. If not, see <http://www.gnu.org/licenses/>.
LICENSE"""
from fat_ffipd.test.TestFramework import _TestFramework
from fat_ffipd.bg_tasks import bg_tasks
from fat_ffipd.background import bg_tasks
class TestBackgroundTasks(_TestFramework):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment