Beispiel #1
0
    def setUp(self):
        super(TestAccountServer, self).setUp()
        _, _, self.redis_host, self.redis_port = self.get_service('redis')
        conf = {'redis_host': self.redis_host, 'redis_port': self.redis_port}
        self.account_id = 'test'

        self.app = create_app(conf).test_client()
        self._create_account()
Beispiel #2
0
    def setUp(self):
        super(TestAccountServer, self).setUp()
        h, p = self.conf['redis'].split(':', 2)
        self.redis_host, self.redis_port = h, int(p)
        conf = {'redis_host': self.redis_host,
                'redis_port': self.redis_port}
        self.account_id = 'test'

        self.app = create_app(conf).test_client()
        self._create_account()
Beispiel #3
0
    def setUp(self):
        super(TestAccountServerBase, self).setUp()
        _, _, self.redis_host, self.redis_port = self.get_service('redis')
        # Make IAM use the second database so we can flush it between tests
        iam_cnxstr = 'redis://%s:%s/?db=1&allow_empty_policy_name=False' % (
            self.redis_host, self.redis_port)
        conf = {
            'redis_host': self.redis_host,
            'redis_port': self.redis_port,
            'namespace': self.ns,
            'iam.connection': iam_cnxstr
        }
        self.account_id = 'test'

        self.acct_app = create_app(conf)
        self.app = Client(self.acct_app, BaseResponse)