2424from osc_lib import exceptions
2525from osc_lib import utils as common_utils
2626from oslo_utils import timeutils
27- import six
2827
2928from openstackclient .compute .v2 import server
3029from openstackclient .tests .unit .compute .v2 import fakes as compute_fakes
@@ -1908,7 +1907,7 @@ def test_server_create_volume_boot_from_volume_conflict(self):
19081907 self .cmd .take_action , parsed_args )
19091908 # Assert it is the error we expect.
19101909 self .assertIn ('--volume is not allowed with --boot-from-volume' ,
1911- six . text_type (ex ))
1910+ str (ex ))
19121911
19131912 def test_server_create_image_property (self ):
19141913 arglist = [
@@ -3289,7 +3288,7 @@ def test_server_migrate_with_host_pre_2_56(self):
32893288 # Make sure it's the error we expect.
32903289 self .assertIn ('--os-compute-api-version 2.56 or greater is required '
32913290 'to use --host without --live-migration.' ,
3292- six . text_type (ex ))
3291+ str (ex ))
32933292
32943293 self .servers_mock .get .assert_called_with (self .server .id )
32953294 self .assertNotCalled (self .servers_mock .live_migrate )
@@ -3324,7 +3323,7 @@ def test_server_live_migrate(self):
33243323 # A warning should have been logged for using --live.
33253324 mock_warning .assert_called_once ()
33263325 self .assertIn ('The --live option has been deprecated.' ,
3327- six . text_type (mock_warning .call_args [0 ][0 ]))
3326+ str (mock_warning .call_args [0 ][0 ]))
33283327
33293328 def test_server_live_migrate_host_pre_2_30 (self ):
33303329 # Tests that the --host option is not supported for --live-migration
@@ -3347,7 +3346,7 @@ def test_server_live_migrate_host_pre_2_30(self):
33473346
33483347 # Make sure it's the error we expect.
33493348 self .assertIn ('--os-compute-api-version 2.30 or greater is required '
3350- 'when using --host' , six . text_type (ex ))
3349+ 'when using --host' , str (ex ))
33513350
33523351 self .servers_mock .get .assert_called_with (self .server .id )
33533352 self .assertNotCalled (self .servers_mock .live_migrate )
@@ -3437,7 +3436,7 @@ def test_server_live_migrate_without_host_override_live(self):
34373436 # A warning should have been logged for using --live.
34383437 mock_warning .assert_called_once ()
34393438 self .assertIn ('The --live option has been deprecated.' ,
3440- six . text_type (mock_warning .call_args [0 ][0 ]))
3439+ str (mock_warning .call_args [0 ][0 ]))
34413440
34423441 def test_server_live_migrate_live_and_host_mutex (self ):
34433442 # Tests specifying both the --live and --host options which are in a
@@ -4353,7 +4352,7 @@ def test_server_resize_confirm(self):
43534352 # A warning should have been logged for using --confirm.
43544353 mock_warning .assert_called_once ()
43554354 self .assertIn ('The --confirm option has been deprecated.' ,
4356- six . text_type (mock_warning .call_args [0 ][0 ]))
4355+ str (mock_warning .call_args [0 ][0 ]))
43574356
43584357 def test_server_resize_revert (self ):
43594358 arglist = [
@@ -4378,7 +4377,7 @@ def test_server_resize_revert(self):
43784377 # A warning should have been logged for using --revert.
43794378 mock_warning .assert_called_once ()
43804379 self .assertIn ('The --revert option has been deprecated.' ,
4381- six . text_type (mock_warning .call_args [0 ][0 ]))
4380+ str (mock_warning .call_args [0 ][0 ]))
43824381
43834382 @mock .patch .object (common_utils , 'wait_for_status' , return_value = True )
43844383 def test_server_resize_with_wait_ok (self , mock_wait_for_status ):
0 commit comments