Example #1
0
    def test_register_connection_ok(self):
        register_connection(
            self.alias, host=self.host, port=self.port
        )

        space = get_space(self.alias, reconnect=True)
        self.assert_space(space, self.space)
Example #2
0
    def setUp(self):
        self.tnt_config = {
            'host': '127.0.0.1',
            'port': 33013,
        }
        self.another_space_alias = 'the_new_space'
        self.composite_primary_key_alias = 'composite_primary_key'

        register_connection(DEFAULT_ALIAS, space=0, **self.tnt_config)
        register_connection(self.another_space_alias,
                            space=1,
                            **self.tnt_config)
        register_connection(self.composite_primary_key_alias,
                            space=2,
                            **self.tnt_config)

        self.space = get_space(DEFAULT_ALIAS)
        self.another_space = get_space(self.another_space_alias)
        self.composite_primary_key_space = get_space(
            self.composite_primary_key_alias)
Example #3
0
    def setUp(self):
        self.tnt_config = {
            'host': '127.0.0.1',
            'port': 33013,
        }
        self.another_space_alias = 'the_new_space'
        self.composite_primary_key_alias = 'composite_primary_key'

        register_connection(
            DEFAULT_ALIAS, space=0, **self.tnt_config
        )
        register_connection(
            self.another_space_alias, space=1, **self.tnt_config
        )
        register_connection(
            self.composite_primary_key_alias, space=2, **self.tnt_config
        )

        self.space = get_space(DEFAULT_ALIAS)
        self.another_space = get_space(self.another_space_alias)
        self.composite_primary_key_space = get_space(self.composite_primary_key_alias)
Example #4
0
    def test_register_connection_ok(self):
        register_connection(self.alias, host=self.host, port=self.port)

        space = get_space(self.alias, reconnect=True)
        self.assert_space(space, self.space)