nova/nova/tests/unit/api/openstack/compute
Victor Stinner b259659a22 Use six.moves.range for Python 3
The function xrange() was renamed to range() in Python 3.

Use "from six.moves import range" to get xrange() on Python 2 and range() on
Python 3 as the name "range", and replace "xrange()" with "range()".

The import is omitted for small ranges (1024 items or less).

This patch was generated by the following tool (revision 0c1d096b3903)
with the "xrange" operation:
https://bitbucket.org/haypo/misc/src/tip/python/sixer.py

Manual change:

* Replace range(n) with list(range(n)) in a loop of
  nova/virt/libvirt/driver.py which uses list.pop()

Blueprint nova-python3
Change-Id: Iceda35cace04cc8ddc6adbd59df4613b22b39793
2015-05-20 15:19:51 -07:00
..
contrib Use six.moves.range for Python 3 2015-05-20 15:19:51 -07:00
extensions move all tests to nova/tests/unit 2014-11-12 15:31:08 -05:00
plugins Use six.moves.range for Python 3 2015-05-20 15:19:51 -07:00
test_plugins Add api microvesion unit test case for wsgi.action 2015-03-17 14:49:34 +08:00
__init__.py move all tests to nova/tests/unit 2014-11-12 15:31:08 -05:00
admin_only_action_common.py Use controller method in all admin actions tests 2015-03-09 09:39:27 +09:00
test_api.py Switch to using oslo_* instead of oslo.* 2015-02-06 06:03:10 -05:00
test_auth.py Fix infinite recursion caused by unnecessary stub 2015-03-11 23:16:07 -05:00
test_consoles.py Add policy check for consoles 2015-03-20 03:45:45 +08:00
test_extensions.py Rename and move the v2.1 api policy into separated files 2015-03-19 14:24:47 -04:00
test_flavors.py Change v3 import to v21 in 2.1 api unit test 2015-03-02 13:37:38 +08:00
test_image_metadata.py Removed twice declared variables 2015-04-29 15:26:50 +03:00
test_images.py V2.1 cleanup: Use concrete NotFound exception instead of generic 2015-02-13 19:21:05 +08:00
test_limits.py Use six.moves.range for Python 3 2015-05-20 15:19:51 -07:00
test_microversions.py Add api microvesion unit test case for wsgi.action 2015-03-17 14:49:34 +08:00
test_plugin_framework.py Switch to using oslo_* instead of oslo.* 2015-02-06 06:03:10 -05:00
test_server_actions.py Replace iter.next() with next(iter) 2015-05-13 11:17:05 +02:00
test_server_metadata.py Rename and move the v2.1 api policy into separated files 2015-03-19 14:24:47 -04:00
test_servers.py Use six.moves.range for Python 3 2015-05-20 15:19:51 -07:00
test_urlmap.py Convert v2.1 extension_info to show V2 API extension list 2015-02-09 09:52:32 +10:30
test_v3_auth.py Fix infinite recursion caused by unnecessary stub 2015-03-11 23:16:07 -05:00
test_v3_extensions.py Switch to using oslo_* instead of oslo.* 2015-02-06 06:03:10 -05:00
test_v21_extensions.py Switch to using oslo_* instead of oslo.* 2015-02-06 06:03:10 -05:00
test_versions.py Add min/max of API microversions to version API 2015-04-14 05:53:07 +00:00