mirror of
https://github.com/github/octodns.git
synced 2024-05-11 05:55:00 +00:00
GoogleCloud python3
This commit is contained in:
@@ -193,9 +193,14 @@ class DummyIterator:
|
||||
def __iter__(self):
|
||||
return self
|
||||
|
||||
# python2
|
||||
def next(self):
|
||||
return next(self.iterable)
|
||||
|
||||
# python3
|
||||
def __next__(self):
|
||||
return next(self.iterable)
|
||||
|
||||
|
||||
class TestGoogleCloudProvider(TestCase):
|
||||
@patch('octodns.provider.googlecloud.dns')
|
||||
@@ -247,7 +252,7 @@ class TestGoogleCloudProvider(TestCase):
|
||||
return_values_for_status = iter(
|
||||
["pending"] * 11 + ['done', 'done'])
|
||||
type(status_mock).status = PropertyMock(
|
||||
side_effect=return_values_for_status.next)
|
||||
side_effect=lambda: next(return_values_for_status))
|
||||
gcloud_zone_mock.changes = Mock(return_value=status_mock)
|
||||
|
||||
provider = self._get_provider()
|
||||
|
||||
Reference in New Issue
Block a user