Merge "Replaces map() with six.moves.map() to provide py2/3 compatibility"
This commit is contained in:
commit
95cd2cd4be
contrib/tempest/dns_tests
@ -12,6 +12,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import six
|
||||
from tempest.api.dns import base
|
||||
from tempest.common.utils import data_utils
|
||||
from tempest import exceptions
|
||||
@ -51,7 +52,8 @@ class ServersAdminTestJSON(base.BaseDnsAdminTest):
|
||||
_, servers = self.client.list_servers()
|
||||
# Verify servers created in setup class are in the list
|
||||
for server in self.setup_servers:
|
||||
self.assertIn(server['id'], map(lambda x: x['id'], servers))
|
||||
self.assertIn(server['id'],
|
||||
six.moves.map(lambda x: x['id'], servers))
|
||||
|
||||
@test.attr(type='smoke')
|
||||
def test_create_update_get_delete_server(self):
|
||||
|
@ -13,6 +13,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import six
|
||||
from tempest.api.dns import base
|
||||
from tempest.common.utils import data_utils
|
||||
from tempest import exceptions
|
||||
@ -50,7 +51,8 @@ class DnsDomainsTest(base.BaseDnsTest):
|
||||
_, domains = self.client.list_domains()
|
||||
# Verify domains created in setup class are in the list
|
||||
for domain in self.setup_domains:
|
||||
self.assertIn(domain['id'], map(lambda x: x['id'], domains))
|
||||
self.assertIn(domain['id'],
|
||||
six.moves.map(lambda x: x['id'], domains))
|
||||
|
||||
@test.attr(type='smoke')
|
||||
def test_create_update_get_domain(self):
|
||||
|
@ -13,6 +13,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import six
|
||||
from tempest.api.dns import base
|
||||
from tempest.common.utils import data_utils
|
||||
from tempest import exceptions
|
||||
@ -62,7 +63,8 @@ class RecordsTest(base.BaseDnsTest):
|
||||
_, records = self.client.list_records(self.domain['id'])
|
||||
# Verify records created in setup class are in the list
|
||||
for record in self.setup_records:
|
||||
self.assertIn(record['id'], map(lambda x: x['id'], records))
|
||||
self.assertIn(record['id'],
|
||||
six.moves.map(lambda x: x['id'], records))
|
||||
|
||||
@test.attr(type='smoke')
|
||||
def test_create_update_get_delete_record(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user