From 4aa9979c60ed5928b8625b6c77c1adcc8b01f575 Mon Sep 17 00:00:00 2001 From: "Sayoko.K" Date: Sun, 9 Jan 2022 20:59:20 +0900 Subject: [PATCH] fix conoha provider (specify auth_region when get provider option) (#949) * fix conoha provider (specify auth_region when get provider option) * fix conoha provider (fix testcase) Co-authored-by: Adrien Ferrand --- lexicon/providers/conoha.py | 4 ++-- lexicon/tests/providers/test_conoha.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lexicon/providers/conoha.py b/lexicon/providers/conoha.py index 48d6e0aa3..5a7eeb401 100644 --- a/lexicon/providers/conoha.py +++ b/lexicon/providers/conoha.py @@ -46,10 +46,10 @@ def __init__(self, config): self.domain_id = None self.api_endpoint = "https://dns-service.{0}.conoha.io/v1".format( - self._get_provider_option("region") or "tyo1" + self._get_provider_option("auth_region") or "tyo1" ) self.auth_api_endpoint = "https://identity.{0}.conoha.io/v2.0".format( - self._get_provider_option("region") or "tyo1" + self._get_provider_option("auth_region") or "tyo1" ) self.auth_token = None diff --git a/lexicon/tests/providers/test_conoha.py b/lexicon/tests/providers/test_conoha.py index b1b08f254..0141857ca 100644 --- a/lexicon/tests/providers/test_conoha.py +++ b/lexicon/tests/providers/test_conoha.py @@ -14,7 +14,7 @@ class ConohaProviderTests(TestCase, IntegrationTestsV2): domain = "narusejun.com" def _test_parameters_overrides(self): - return {"region": "tyo1"} + return {"auth_region": "tyo1"} def _test_fallback_fn(self): return lambda x: None if x in ("priority") else "placeholder_" + x