Exemplo n.º 1
0
    def test_config_load_extension(self):
        from empty import Empty
        from empty import EmptyConfig

        config = EmptyConfig(EXTENSIONS=['extensions.ext'])
        app = Empty('myapp')
        app.configure(config)
        app.setup()
        ext = app.extensions['ext']
        self.assertTrue('test' in ext.options)
Exemplo n.º 2
0
    def test_config_load_extension(self):
        from empty import Empty
        from empty import EmptyConfig

        config = EmptyConfig(EXTENSIONS=[
            'extensions.ext'
        ])
        app = Empty('myapp')
        app.configure(config)
        app.setup()
        ext = app.extensions['ext']
        self.assertTrue('test' in ext.options)
Exemplo n.º 3
0
    def create_app(self):
        from empty import Empty

        app = Empty('myapp')
        app.setup()
        return app