def test_connector_with_multi_tenants(self): set_tenant_map({get_unittest_tenant_name(): 'NC', 'b': 'AB'}) dummy_session = DummySession() dummy_session.set_tenants([get_unittest_tenant_name(), 'dummyTenant']) self.__config.testing_securitypolicy(dummy_session) conn = EdCoreDBConnection(state_code='NC') self.assertIsInstance(conn, EdCoreDBConnection) dim_student = conn.get_table('dim_student') self.assertEqual(dim_student.name, 'dim_student')
def test_connector_with_one_tenant(self): conn = EdCoreDBConnection() self.assertIsInstance(conn, EdCoreDBConnection) dim_student = conn.get_table('dim_student') self.assertEqual(dim_student.name, 'dim_student')
def test_connector(self): conn = EdCoreDBConnection(tenant=get_unittest_tenant_name()) self.assertIsInstance(conn, EdCoreDBConnection) dim_student = conn.get_table('dim_student') self.assertEqual(dim_student.name, 'dim_student')