Cleanup py27 support
This repo is now testing only with Python 3, so let's make a few cleanups: - Remove now unused files babel.cfg and openstack-common.conf. - Remove use of six library. - Update to hacking 3.1.0 - Update pbr requirement Change-Id: Ib4b9460f24cfaa216f0302b3b90ef73d808eb3e4
This commit is contained in:
parent
57582a48bb
commit
3c4adf44e1
|
@ -1,6 +0,0 @@
|
||||||
[DEFAULT]
|
|
||||||
|
|
||||||
# The list of modules to copy from oslo-incubator.git
|
|
||||||
|
|
||||||
# The base module to hold the copy of openstack.common
|
|
||||||
base=os_performance_tools
|
|
|
@ -19,11 +19,11 @@ be ignored by this module. Everything from the "client" section will be passed
|
||||||
through to pymysql's connect method.
|
through to pymysql's connect method.
|
||||||
'''
|
'''
|
||||||
|
|
||||||
|
import configparser
|
||||||
import logging
|
import logging
|
||||||
import os
|
import os
|
||||||
|
|
||||||
import pymysql
|
import pymysql
|
||||||
from six.moves import configparser
|
|
||||||
|
|
||||||
from os_performance_tools import error
|
from os_performance_tools import error
|
||||||
|
|
||||||
|
|
|
@ -25,13 +25,13 @@ so we strip that off.
|
||||||
'''
|
'''
|
||||||
|
|
||||||
import base64
|
import base64
|
||||||
|
import http.client as http_client
|
||||||
import json
|
import json
|
||||||
import logging
|
import logging
|
||||||
import os
|
import os
|
||||||
import re
|
import re
|
||||||
import socket
|
import socket
|
||||||
|
|
||||||
from six.moves import http_client
|
|
||||||
|
|
||||||
from os_performance_tools import error
|
from os_performance_tools import error
|
||||||
|
|
||||||
|
|
|
@ -17,13 +17,13 @@ test_collect
|
||||||
Tests for `os_performance_tools.collect`
|
Tests for `os_performance_tools.collect`
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
import io
|
||||||
import json
|
import json
|
||||||
import mock
|
import mock
|
||||||
import tempfile
|
import tempfile
|
||||||
|
|
||||||
from os_performance_tools import collect
|
from os_performance_tools import collect
|
||||||
from os_performance_tools.tests import base
|
from os_performance_tools.tests import base
|
||||||
import six
|
|
||||||
import subunit
|
import subunit
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
|
@ -45,7 +45,7 @@ class TestCollect(base.TestCase):
|
||||||
|
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
super(TestCollect, self).setUp()
|
super(TestCollect, self).setUp()
|
||||||
self.stdout = six.BytesIO()
|
self.stdout = io.BytesIO()
|
||||||
self.attachments = []
|
self.attachments = []
|
||||||
|
|
||||||
@mock.patch('os_performance_tools.collectors.mysql.collect')
|
@mock.patch('os_performance_tools.collectors.mysql.collect')
|
||||||
|
|
|
@ -26,7 +26,7 @@ from os_performance_tools.tests import base
|
||||||
|
|
||||||
class TestOpenStackQaTols(base.TestCase):
|
class TestOpenStackQaTols(base.TestCase):
|
||||||
|
|
||||||
@mock.patch('six.moves.http_client.HTTPConnection')
|
@mock.patch('http.client.HTTPConnection')
|
||||||
def test_queues(self, httplib_mock):
|
def test_queues(self, httplib_mock):
|
||||||
reader = mock.MagicMock(name='getresponse_reader')
|
reader = mock.MagicMock(name='getresponse_reader')
|
||||||
rval = json.dumps([{'name': 'foo', 'message_stats': {'publish': 1}}])
|
rval = json.dumps([{'name': 'foo', 'message_stats': {'publish': 1}}])
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# of appearance. Changing the order has an impact on the overall integration
|
# of appearance. Changing the order has an impact on the overall integration
|
||||||
# process, which may cause wedges in the gate later.
|
# process, which may cause wedges in the gate later.
|
||||||
|
|
||||||
pbr>=1.6
|
pbr>=2.0,!=2.1.0
|
||||||
PyMySQL>=0.6.2 # MIT License
|
PyMySQL>=0.6.2 # MIT License
|
||||||
statsd>=1.0.0
|
statsd>=1.0.0
|
||||||
oslo.config>=1.4.0.0a3
|
oslo.config>=1.4.0.0a3
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# of appearance. Changing the order has an impact on the overall integration
|
# of appearance. Changing the order has an impact on the overall integration
|
||||||
# process, which may cause wedges in the gate later.
|
# process, which may cause wedges in the gate later.
|
||||||
|
|
||||||
hacking<3.1.0,>=3.0.1
|
hacking<3.2.0,>=3.1.0
|
||||||
|
|
||||||
coverage>=3.6
|
coverage>=3.6
|
||||||
python-subunit>=0.0.18
|
python-subunit>=0.0.18
|
||||||
|
|
Loading…
Reference in New Issue