當前位置: 首頁>>代碼示例>>Python>>正文


Python Code.SUCCESS屬性代碼示例

本文整理匯總了Python中oslo_upgradecheck.upgradecheck.Code.SUCCESS屬性的典型用法代碼示例。如果您正苦於以下問題:Python Code.SUCCESS屬性的具體用法?Python Code.SUCCESS怎麽用?Python Code.SUCCESS使用的例子?那麽, 這裏精選的屬性代碼示例或許可以為您提供幫助。您也可以進一步了解該屬性所在oslo_upgradecheck.upgradecheck.Code的用法示例。


在下文中一共展示了Code.SUCCESS屬性的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: test__numactl_check_ok

# 需要導入模塊: from oslo_upgradecheck.upgradecheck import Code [as 別名]
# 或者: from oslo_upgradecheck.upgradecheck.Code import SUCCESS [as 別名]
def test__numactl_check_ok(self, mock_cmd_exists):
        mock_cmd_exists.return_value = True
        check_result = self.cmd._numactl_check()
        self.assertEqual(
            Code.SUCCESS, check_result.code) 
開發者ID:openstack,項目名稱:zun,代碼行數:7,代碼來源:test_status.py

示例2: test__sample_check

# 需要導入模塊: from oslo_upgradecheck.upgradecheck import Code [as 別名]
# 或者: from oslo_upgradecheck.upgradecheck.Code import SUCCESS [as 別名]
def test__sample_check(self):
        check_result = self.cmd._sample_check()
        self.assertEqual(
            Code.SUCCESS, check_result.code) 
開發者ID:openstack,項目名稱:octavia,代碼行數:6,代碼來源:test_status.py

示例3: test__check_placeholder

# 需要導入模塊: from oslo_upgradecheck.upgradecheck import Code [as 別名]
# 或者: from oslo_upgradecheck.upgradecheck.Code import SUCCESS [as 別名]
def test__check_placeholder(self):
        check_result = self.cmd._check_placeholder()
        self.assertEqual(
            Code.SUCCESS, check_result.code) 
開發者ID:openstack,項目名稱:freezer-api,代碼行數:6,代碼來源:test_status.py

示例4: test_minimum_nova_api_version_ok

# 需要導入模塊: from oslo_upgradecheck.upgradecheck import Code [as 別名]
# 或者: from oslo_upgradecheck.upgradecheck.Code import SUCCESS [as 別名]
def test_minimum_nova_api_version_ok(self):
        # Tests that the default [nova_client]/api_version meets the minimum
        # required version.
        result = self.cmd._minimum_nova_api_version()
        self.assertEqual(Code.SUCCESS, result.code) 
開發者ID:openstack,項目名稱:watcher,代碼行數:7,代碼來源:test_status.py

示例5: test__check_placeholder

# 需要導入模塊: from oslo_upgradecheck.upgradecheck import Code [as 別名]
# 或者: from oslo_upgradecheck.upgradecheck.Code import SUCCESS [as 別名]
def test__check_placeholder(self):
        check_result = self.cmd._check_placeholder()
        self.assertEqual(
            Code.SUCCESS, check_result.code,
            "Placeholder should always succeed.") 
開發者ID:openstack,項目名稱:monasca-api,代碼行數:7,代碼來源:test_status.py

示例6: test__check_healthpolicy_success

# 需要導入模塊: from oslo_upgradecheck.upgradecheck import Code [as 別名]
# 或者: from oslo_upgradecheck.upgradecheck.Code import SUCCESS [as 別名]
def test__check_healthpolicy_success(self):
        healthpolv1_1 = db_api.policy_create(self.ctx, self.healthpolv1_1_data)
        self.addCleanup(db_api.policy_delete, self.ctx, healthpolv1_1.id)

        scalepol = db_api.policy_create(self.ctx, self.scalepol_data)
        self.addCleanup(db_api.policy_delete, self.ctx, scalepol.id)

        check_result = self.cmd._check_healthpolicy()
        self.assertEqual(Code.SUCCESS, check_result.code) 
開發者ID:openstack,項目名稱:senlin,代碼行數:11,代碼來源:test_status.py


注:本文中的oslo_upgradecheck.upgradecheck.Code.SUCCESS屬性示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。