Ejemplo n.º 1
0
    def setUp(self):
        self.db_uri = get_test_db_uri()
        self.db_context = sqlalchemy_setup(self.db_uri)
        self.admin_emails = ['*****@*****.**', '*****@*****.**']
        self.config = testing.setUp(settings={
            'admin_emails': self.admin_emails,
            'database_url': get_test_db_uri(),
        })
        self.config.include('pyramid_mailer.testing')
        self.config.include('pyramid_chameleon')

        self.config.include('yithlibraryserver.contributions')
        self.config.include('yithlibraryserver.user')
        self.config.add_route('home', '/')

        self.donation = Donation(
            amount=10,
            first_name='John',
            last_name='Doe',
            city='Springfield',
            country='Exampleland',
            state='Example',
            street='Main Street 10',
            zipcode='12345678',
            email='*****@*****.**',
            send_sticker=True,
        )
Ejemplo n.º 2
0
 def setUp(self):
     self.db_uri = get_test_db_uri()
     self.db_context = sqlalchemy_setup(self.db_uri)
     self.config = testing.setUp()
     self.config.include('yithlibraryserver.password')
     self.config.include('yithlibraryserver.user')
     metadata.create_all()
Ejemplo n.º 3
0
    def setUp(self):
        self.db_uri = get_test_db_uri()
        self.db_context = sqlalchemy_setup(self.db_uri)
        self.admin_emails = ['*****@*****.**', '*****@*****.**']
        self.config = testing.setUp(settings={
            'admin_emails': self.admin_emails,
            'database_url': get_test_db_uri(),
        })
        self.config.include('pyramid_mailer.testing')
        self.config.include('pyramid_chameleon')

        self.config.include('yithlibraryserver.contributions')
        self.config.include('yithlibraryserver.user')
        self.config.add_route('home', '/')

        self.donation = Donation(
            amount=10,
            first_name='John',
            last_name='Doe',
            city='Springfield',
            country='Exampleland',
            state='Example',
            street='Main Street 10',
            zipcode='12345678',
            email='*****@*****.**',
            send_sticker=True,
        )
Ejemplo n.º 4
0
 def setUp(self):
     self.db_uri = get_test_db_uri()
     self.db_context = sqlalchemy_setup(self.db_uri)
     self.config = testing.setUp()
     self.config.include('yithlibraryserver.password')
     self.config.include('yithlibraryserver.user')
     metadata.create_all()
Ejemplo n.º 5
0
    def setUp(self):
        fd, self.conf_file_path = tempfile.mkstemp()
        os.write(fd, CONFIG.encode('ascii'))
        if self.use_db:
            self.db_uri = get_test_db_uri()
            self.db_context = sqlalchemy_setup(self.db_uri)

            metadata.create_all()
Ejemplo n.º 6
0
    def setUp(self):
        self.db_uri = get_test_db_uri()
        self.db_context = sqlalchemy_setup(self.db_uri)

        self.config = testing.setUp()
        self.config.include('pyramid_mailer.testing')
        self.config.include('pyramid_chameleon')
        self.config.include('yithlibraryserver.user')

        metadata.create_all()
    def setUp(self):
        self.db_uri = get_test_db_uri()
        self.db_context = sqlalchemy_setup(self.db_uri)

        self.config = testing.setUp()
        self.config.include('pyramid_mailer.testing')
        self.config.include('pyramid_chameleon')
        self.config.include('yithlibraryserver.user')

        metadata.create_all()
    def setUp(self):
        self.db_uri = get_test_db_uri()
        self.db_context = sqlalchemy_setup(self.db_uri)

        self.config = testing.setUp()
        self.config.include('yithlibraryserver')
        self.config.include('yithlibraryserver.user')

        metadata.create_all()

        self.request = testing.DummyRequest()
        self.request.session = {}
Ejemplo n.º 9
0
    def setUp(self):
        self.db_uri = get_test_db_uri()
        self.db_context = sqlalchemy_setup(self.db_uri)

        self.config = testing.setUp()
        self.config.include('yithlibraryserver')
        self.config.include('yithlibraryserver.user')

        metadata.create_all()

        self.request = testing.DummyRequest()
        self.request.session = {}