All Downloads are FREE. Search and download functionalities are using the official Maven repository.

python-flask.__init__test.mustache Maven / Gradle / Ivy

There is a newer version: 7.8.0
Show newest version
import logging

import connexion
from flask_testing import TestCase

from {{packageName}}.encoder import JSONEncoder


class BaseTestCase(TestCase):

    def create_app(self):
        logging.getLogger('connexion.operation').setLevel('ERROR')
        app = connexion.App(__name__, specification_dir='../openapi/')
        app.app.json_encoder = JSONEncoder
        app.add_api('openapi.yaml', pythonic_params=True)
        return app.app




© 2015 - 2024 Weber Informatics LLC | Privacy Policy