Example #1
0
def test_app_no_environment():
    with patch('bas_web_map_inventory._create_app_config'
               ) as mock_create_app_config:
        config = Config()
        mock_create_app_config.return_value = config

        app = create_app()
        assert app is not None
        assert isinstance(app, Flask)
        assert app.config['TESTING'] is False
Example #2
0
def test_app_enable_sentry():
    with patch('bas_web_map_inventory._create_app_config'
               ) as mock_create_app_config:
        config = _TestingConfig()
        config.APP_ENABLE_SENTRY = True
        mock_create_app_config.return_value = config

        app = create_app()
        assert app is not None
        assert isinstance(app, Flask)
        assert app.config['TESTING'] is True
        assert app.config['APP_ENABLE_SENTRY'] is True
Example #3
0
from bas_web_map_inventory import create_app

app = create_app()
Example #4
0
def app():
    app = create_app()
    return app