Merge "Keep py3.X compatibility for urllib"
This commit is contained in:
		| @@ -21,9 +21,10 @@ import inspect | |||||||
| import os | import os | ||||||
| import sys | import sys | ||||||
| import unittest | import unittest | ||||||
| import urllib |  | ||||||
| import uuid | import uuid | ||||||
|  |  | ||||||
|  | import six.moves.urllib.parse as urlparse | ||||||
|  |  | ||||||
| DECORATOR_MODULE = 'test' | DECORATOR_MODULE = 'test' | ||||||
| DECORATOR_NAME = 'idempotent_id' | DECORATOR_NAME = 'idempotent_id' | ||||||
| DECORATOR_IMPORT = 'tempest.%s' % DECORATOR_MODULE | DECORATOR_IMPORT = 'tempest.%s' % DECORATOR_MODULE | ||||||
| @@ -49,11 +50,11 @@ class SourcePatcher(object): | |||||||
|  |  | ||||||
|     @staticmethod |     @staticmethod | ||||||
|     def _quote(s): |     def _quote(s): | ||||||
|         return urllib.quote(s) |         return urlparse.quote(s) | ||||||
|  |  | ||||||
|     @staticmethod |     @staticmethod | ||||||
|     def _unquote(s): |     def _unquote(s): | ||||||
|         return urllib.unquote(s) |         return urlparse.unquote(s) | ||||||
|  |  | ||||||
|     def add_patch(self, filename, patch, line_no): |     def add_patch(self, filename, patch, line_no): | ||||||
|         """Add lazy patch""" |         """Add lazy patch""" | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Jenkins
					Jenkins