Esempio n. 1
0
class TestPoolManager(unittest.TestCase):
    @classmethod
    def setUpClass(cls):
        logging.disable(logging.CRITICAL)

    @classmethod
    def tearDownClass(cls):
        logging.disable(logging.NOTSET)

    def setUp(self):
        self.pool_manager = PoolManager(organization_name=ORGANIZATION_NAME,
                                        project_name=PROJECT_NAME,
                                        creds=get_credentials())

    def tearDown(self):
        self.pool_manager.close_connection()

    def test_list_pools(self):
        pools = self.pool_manager.list_pools()
        self.assertIsNotNone(pools)
        self.assertIsNotNone(pools.value)
        self.assertGreaterEqual(pools.count, 0)
Esempio n. 2
0
 def list_pools(self, organization_name, project_name):
     """List the devops pool resources"""
     pool_manager = PoolManager(organization_name=organization_name, project_name=project_name, creds=self._creds)
     return pool_manager.list_pools()
 def list_pools(self, organization_name, project_name):
     """List the devops pool resources"""
     pool_manager = PoolManager(organization_name=organization_name, project_name=project_name, creds=self._creds)
     return pool_manager.list_pools()
Esempio n. 4
0
 def setUp(self):
     self.pool_manager = PoolManager(organization_name=ORGANIZATION_NAME,
                                     project_name=PROJECT_NAME,
                                     creds=get_credentials())