# Path: beavy/app.py
# BASE_DIR = os.path.dirname(os.path.abspath(__file__))
# STATIC_FOLDER = os.path.join(BASE_DIR, '..', 'assets')
#     _FLBLPRE = "flask_social_blueprint.providers.{}"
# def make_env(app):
# def setup_statics(app):
#     def injnect_manifest():
# def make_celery(app):
#         def __call__(self, *args, **kwargs):
#     def login_failed_redirect(self, profile, provider):
#     def is_accessible(self):
# def _limiter_key():
# def inject_messages():
# def get_locale():
#     def ensure_users():
#     def print_routes():
#     class ContextTask(TaskBase):
# class SocialBlueprint(SocialBp):
# class BeavyAdminIndexView(AdminIndexView):


from flask.ext.script import Command, Option
from beavy.app import app, manager, migrate
    from behave.configuration import options as behave_options
    from behave.__main__ import main as behave_main
import sys
import os
import re
    import pytest
    import pytest
        if "config_help" in kwargs:
            del kwargs['config_help']
        res.append(Option(*args, **kwargs))
    return res


def get_all_beavy_paths(fn):
    fn("beavy")

    for module in app.config.get("MODULES", []):
        fn("beavy_modules/{}".format(module))

    return fn("beavy_apps/{}".format(app.config["APP"]))


class Behave(Command):

    def get_options(self):
        return reformat_options(behave_options)

    def run(self, *args, **kwargs):
        frontend = os.environ.get("APP", app.config.get("APP", None))
        if not frontend:
            print("You need to configure the APP to be used!")
            exit(1)

        exit(behave_main(sys.argv[2:] + ['--no-capture',
             "beavy_apps/{}/tests/features".format(frontend)]))

if has_behave:

# Path: beavy/app.py
# BASE_DIR = os.path.dirname(os.path.abspath(__file__))
# STATIC_FOLDER = os.path.join(BASE_DIR, '..', 'assets')
#     _FLBLPRE = "flask_social_blueprint.providers.{}"
# def make_env(app):
# def setup_statics(app):
#     def injnect_manifest():
# def make_celery(app):
#         def __call__(self, *args, **kwargs):
#     def login_failed_redirect(self, profile, provider):
#     def is_accessible(self):
# def _limiter_key():
# def inject_messages():
# def get_locale():
#     def ensure_users():
#     def print_routes():
#     class ContextTask(TaskBase):
# class SocialBlueprint(SocialBp):
# class BeavyAdminIndexView(AdminIndexView):


# Path: manager.py
from flask.ext.script import Command, Option
from beavy.app import app, manager, migrate
    from behave.configuration import options as behave_options
    from behave.__main__ import main as behave_main
import sys
import os
import re
    import pytest
    import pytest

        if "config_help" in kwargs:
            del kwargs['config_help']
        res.append(Option(*args, **kwargs))
    return res


def get_all_beavy_paths(fn):
    fn("beavy")

    for module in app.config.get("MODULES", []):
        fn("beavy_modules/{}".format(module))

    return fn("beavy_apps/{}".format(app.config["APP"]))


class Behave(Command):

    def get_options(self):
        return reformat_options(behave_options)

    def run(self, *args, **kwargs):
        frontend = os.environ.get("APP", app.config.get("APP", None))
        if not frontend:
            print("You need to configure the APP to be used!")
            exit(1)

        exit(behave_main(sys.argv[2:] + ['--no-capture',
             "beavy_apps/{}/tests/features".format(frontend)]))

if has_behave:

    manager.add_command("behave", Behave())