akhet generated does not work

Issue #10 new
Anonymous created an issue

When using 'python ./setup.py test' I get this error:

{{{ Traceback (most recent call last): File "/tmp/testapp/testapp/tests.py", line 8, in setUp self.engine = sqlahelper.add_engine(url="sqlite://") TypeError: add_engine() got an unexpected keyword argument 'url' }}}

It seems that recent sqlahelper does not have a 'url' keyword argument for add_engine().

Comments (1)

  1. Anonymous

    Taking from the other templates, here's what I have now, which works well:

    def _initTestingDB():
        from sqlalchemy import create_engine
        from hvac.models import initialize_sql
        session = initialize_sql(create_engine('sqlite://'))
        return session
    class MyHandlerTests(unittest.TestCase):
        def setUp(self):
            from pyramid.config import Configurator
            self.session = _initTestingDB()
            self.config = Configurator(autocommit=True)

    Sorry about the name of this bug, I meant it to say, "akhet generated tests.py does not work," but as I do not have a login, I can't edit it now.

  2. Log in to comment