def test_err_cli_res_to_list(self): with self.assertRaises(Exception) as exc: navi_handler = NaviHandler(**ACCESS_INFO) navi_handler.cli_res_to_list({}) self.assertIn('cli resource to list error', str(exc.exception))
def test_cli_res_to_list(self): navi_handler = NaviHandler(**ACCESS_INFO) re_list = navi_handler.cli_res_to_list(POOL_INFOS) self.assertDictEqual(re_list[0], POOLS_ANALYSE_RESULT[0])