42 +max_meta_name_length = 128 |
43 +max_meta_name_length = 128 |
43 +max_meta_value_length = 256 |
44 +max_meta_value_length = 256 |
44 +max_meta_count = 90 |
45 +max_meta_count = 90 |
45 +max_meta_overall_size = 4096 |
46 +max_meta_overall_size = 4096 |
46 +max_header_size = 8192 |
47 +max_header_size = 8192 |
|
48 +extra_header_count = 0 |
47 +max_object_name_length = 1024 |
49 +max_object_name_length = 1024 |
48 +container_listing_limit = 10000 |
50 +container_listing_limit = 10000 |
49 +account_listing_limit = 10000 |
51 +account_listing_limit = 10000 |
50 +max_account_name_length = 256 |
52 +max_account_name_length = 256 |
51 +max_container_name_length = 256 |
53 +max_container_name_length = 256 |
52 |
54 |
53 # Newer swift versions default to strict cors mode, but older ones were the |
55 # Newer swift versions default to strict cors mode, but older ones were the |
54 # opposite. |
56 # opposite. |
55 --- swift-2.3.0/test/unit/__init__.py.~1~ 2015-04-30 06:57:42.000000000 -0700 |
57 --- swift-2.7.0/test/unit/__init__.py.~1~ 2016-03-25 02:42:55.000000000 -0700 |
56 +++ swift-2.3.0/test/unit/__init__.py 2016-02-08 01:24:17.842339594 -0800 |
58 +++ swift-2.7.0/test/unit/__init__.py 2016-08-08 19:02:28.070402665 -0700 |
57 @@ -817,7 +817,7 @@ def fake_http_connect(*code_iter, **kwar |
59 @@ -903,7 +903,7 @@ def fake_http_connect(*code_iter, **kwar |
58 etag = '"68b329da9893e34099c7d8ad5cb9c940"' |
60 etag = '"68b329da9893e34099c7d8ad5cb9c940"' |
59 |
61 |
60 headers = swob.HeaderKeyDict({ |
62 headers = HeaderKeyDict({ |
61 - 'content-length': len(self.body), |
63 - 'content-length': len(self.body), |
62 + 'content-length': self.body.__len__(), |
64 + 'content-length': self.body.__len__(), |
63 'content-type': 'x-application/test', |
65 'content-type': 'x-application/test', |
64 'x-timestamp': self.timestamp, |
66 'x-timestamp': self.timestamp, |
65 'x-backend-timestamp': self.timestamp, |
67 'x-backend-timestamp': self.timestamp, |
66 --- swift-2.3.0/test/unit/common/test_utils.py.~1~ 2015-04-30 06:57:42.000000000 -0700 |
68 --- swift-2.7.0/test/unit/common/test_utils.py.~1~ 2016-03-25 02:42:55.000000000 -0700 |
67 +++ swift-2.3.0/test/unit/common/test_utils.py 2016-02-08 01:24:17.844724978 -0800 |
69 +++ swift-2.7.0/test/unit/common/test_utils.py 2016-08-08 19:02:28.072989400 -0700 |
68 @@ -53,6 +53,7 @@ from functools import partial |
70 @@ -54,6 +54,7 @@ from functools import partial |
69 from tempfile import TemporaryFile, NamedTemporaryFile, mkdtemp |
71 from tempfile import TemporaryFile, NamedTemporaryFile, mkdtemp |
70 from netifaces import AF_INET6 |
72 from netifaces import AF_INET6 |
71 from mock import MagicMock, patch |
73 from mock import MagicMock, patch |
72 +from nose import SkipTest |
74 +from nose import SkipTest |
|
75 from six.moves.configparser import NoSectionError, NoOptionError |
73 |
76 |
74 from swift.common.exceptions import (Timeout, MessageTimeout, |
77 from swift.common.exceptions import Timeout, MessageTimeout, \ |
75 ConnectionTimeout, LockTimeout, |
78 @@ -916,6 +917,8 @@ class TestUtils(unittest.TestCase): |
76 @@ -748,6 +749,8 @@ class TestUtils(unittest.TestCase): |
|
77 utils.HASH_PATH_PREFIX = 'startcap' |
79 utils.HASH_PATH_PREFIX = 'startcap' |
78 |
80 |
79 def test_lock_path(self): |
81 def test_lock_path(self): |
80 + if sys.platform == 'sunos5': |
82 + if sys.platform == 'sunos5': |
81 + raise SkipTest |
83 + raise SkipTest |
82 tmpdir = mkdtemp() |
84 tmpdir = mkdtemp() |
83 try: |
85 try: |
84 with utils.lock_path(tmpdir, 0.1): |
86 with utils.lock_path(tmpdir, 0.1): |
85 @@ -764,6 +767,8 @@ class TestUtils(unittest.TestCase): |
87 @@ -932,6 +935,8 @@ class TestUtils(unittest.TestCase): |
86 shutil.rmtree(tmpdir) |
88 shutil.rmtree(tmpdir) |
87 |
89 |
88 def test_lock_path_num_sleeps(self): |
90 def test_lock_path_num_sleeps(self): |
89 + if sys.platform == 'sunos5': |
91 + if sys.platform == 'sunos5': |
90 + raise SkipTest |
92 + raise SkipTest |
91 tmpdir = mkdtemp() |
93 tmpdir = mkdtemp() |
92 num_short_calls = [0] |
94 num_short_calls = [0] |
93 exception_raised = [False] |
95 exception_raised = [False] |
94 @@ -788,6 +793,8 @@ class TestUtils(unittest.TestCase): |
96 @@ -956,6 +961,8 @@ class TestUtils(unittest.TestCase): |
95 self.assertTrue(exception_raised[0]) |
97 self.assertTrue(exception_raised[0]) |
96 |
98 |
97 def test_lock_path_class(self): |
99 def test_lock_path_class(self): |
98 + if sys.platform == 'sunos5': |
100 + if sys.platform == 'sunos5': |
99 + raise SkipTest |
101 + raise SkipTest |
100 tmpdir = mkdtemp() |
102 tmpdir = mkdtemp() |
101 try: |
103 try: |
102 with utils.lock_path(tmpdir, 0.1, ReplicationLockTimeout): |
104 with utils.lock_path(tmpdir, 0.1, ReplicationLockTimeout): |
103 @@ -1214,7 +1221,8 @@ class TestUtils(unittest.TestCase): |
105 @@ -1405,7 +1412,8 @@ class TestUtils(unittest.TestCase): |
104 }, 'server', log_route='server') |
106 }, 'server', log_route='server') |
105 expected_args = [((), {'address': '/dev/log', |
107 expected_args = [((), {'address': '/dev/log', |
106 'facility': orig_sysloghandler.LOG_LOCAL3})] |
108 'facility': orig_sysloghandler.LOG_LOCAL3})] |
107 - if not os.path.exists('/dev/log') or \ |
109 - if not os.path.exists('/dev/log') or \ |
108 + if sys.platform == 'sunos5' or \ |
110 + if sys.platform == 'sunos5' or \ |
109 + not os.path.exists('/dev/log') or \ |
111 + not os.path.exists('/dev/log') or \ |
110 os.path.isfile('/dev/log') or \ |
112 os.path.isfile('/dev/log') or \ |
111 os.path.isdir('/dev/log'): |
113 os.path.isdir('/dev/log'): |
112 # Since socket on OSX is in /var/run/syslog, there will be |
114 # Since socket on OSX is in /var/run/syslog, there will be |
113 @@ -2402,6 +2410,8 @@ cluster_dfw1 = http://dfw1.host/v1/ |
115 @@ -2726,6 +2734,8 @@ cluster_dfw1 = http://dfw1.host/v1/ |
114 MagicMock(side_effect=BaseException('test3'))) |
116 MagicMock(side_effect=BaseException('test3'))) |
115 |
117 |
116 def test_lock_file(self): |
118 def test_lock_file(self): |
117 + if sys.platform == 'sunos5': |
119 + if sys.platform == 'sunos5': |
118 + raise SkipTest |
120 + raise SkipTest |
119 flags = os.O_CREAT | os.O_RDWR |
121 flags = os.O_CREAT | os.O_RDWR |
120 with NamedTemporaryFile(delete=False) as nt: |
122 with NamedTemporaryFile(delete=False) as nt: |
121 nt.write("test string") |
123 nt.write("test string") |
122 @@ -2480,6 +2490,8 @@ cluster_dfw1 = http://dfw1.host/v1/ |
124 @@ -2805,6 +2815,8 @@ cluster_dfw1 = http://dfw1.host/v1/ |
123 os.fstat(f.fileno()).st_ino) |
125 os.fstat(f.fileno()).st_ino) |
124 |
126 |
125 def test_lock_file_held_on_unlink(self): |
127 def test_lock_file_held_on_unlink(self): |
126 + if sys.platform == 'sunos5': |
128 + if sys.platform == 'sunos5': |
127 + raise SkipTest |
129 + raise SkipTest |
128 os_unlink = os.unlink |
130 os_unlink = os.unlink |
129 |
131 |
130 def flocking_unlink(filename): |
132 def flocking_unlink(filename): |
131 @@ -2496,6 +2508,8 @@ cluster_dfw1 = http://dfw1.host/v1/ |
133 @@ -2821,6 +2833,8 @@ cluster_dfw1 = http://dfw1.host/v1/ |
132 pass |
134 pass |
133 |
135 |
134 def test_lock_file_no_unlink_if_fail(self): |
136 def test_lock_file_no_unlink_if_fail(self): |
135 + if sys.platform == 'sunos5': |
137 + if sys.platform == 'sunos5': |
136 + raise SkipTest |
138 + raise SkipTest |
137 os_open = os.open |
139 os_open = os.open |
138 with NamedTemporaryFile(delete=True) as nt: |
140 with NamedTemporaryFile(delete=True) as nt: |
139 |
141 |
140 --- swift-2.3.0/test/unit/obj/test_diskfile.py.~1~ 2015-04-30 06:57:42.000000000 -0700 |
142 --- swift-2.7.0/test/unit/obj/test_diskfile.py.~1~ 2016-03-25 02:42:55.000000000 -0700 |
141 +++ swift-2.3.0/test/unit/obj/test_diskfile.py 2016-02-08 01:24:17.846568734 -0800 |
143 +++ swift-2.7.0/test/unit/obj/test_diskfile.py 2016-08-08 19:02:28.075330000 -0700 |
142 @@ -18,6 +18,7 @@ |
144 @@ -18,6 +18,7 @@ |
143 |
145 |
144 import cPickle as pickle |
146 import six.moves.cPickle as pickle |
145 import os |
147 import os |
146 +import sys |
148 +import sys |
147 import errno |
149 import errno |
148 import itertools |
150 import itertools |
149 import mock |
151 from unittest.util import safe_repr |
150 @@ -608,6 +609,8 @@ class DiskFileManagerMixin(BaseDiskFileT |
152 @@ -718,6 +719,8 @@ class DiskFileManagerMixin(BaseDiskFileT |
151 self.assertEqual(locations, []) |
153 self.assertEqual(locations, []) |
152 |
154 |
153 def test_replication_lock_on(self): |
155 def test_replication_lock_on(self): |
154 + if sys.platform == 'sunos5': |
156 + if sys.platform == 'sunos5': |
155 + raise SkipTest |
157 + raise SkipTest |
156 # Double check settings |
158 # Double check settings |
157 self.df_mgr.replication_one_per_device = True |
159 self.df_mgr.replication_one_per_device = True |
158 self.df_mgr.replication_lock_timeout = 0.1 |
160 self.df_mgr.replication_lock_timeout = 0.1 |
159 --- swift-2.3.0/test/unit/proxy/test_server.py.~1~ 2015-04-30 06:57:42.000000000 -0700 |
161 --- swift-2.7.0/test/unit/proxy/test_server.py.~1~ 2016-03-25 02:42:55.000000000 -0700 |
160 +++ swift-2.3.0/test/unit/proxy/test_server.py 2016-02-08 01:24:17.849738022 -0800 |
162 +++ swift-2.7.0/test/unit/proxy/test_server.py 2016-08-08 19:02:28.078178485 -0700 |
161 @@ -4263,6 +4263,9 @@ class TestObjectController(unittest.Test |
163 @@ -4860,6 +4860,9 @@ class TestObjectController(unittest.Test |
162 |
164 |
163 class LargeResponseBody(object): |
165 class LargeResponseBody(object): |
164 |
166 |
165 + def __nonzero__(self): |
167 + def __nonzero__(self): |
166 + return True |
168 + return True |
167 + |
169 + |
168 def __len__(self): |
170 def __len__(self): |
169 return constraints.MAX_FILE_SIZE + 1 |
171 return constraints.MAX_FILE_SIZE + 1 |
170 |
172 |
171 @@ -4510,6 +4513,9 @@ class TestObjectController(unittest.Test |
173 @@ -5107,6 +5110,9 @@ class TestObjectController(unittest.Test |
172 |
174 |
173 class LargeResponseBody(object): |
175 class LargeResponseBody(object): |
174 |
176 |
175 + def __nonzero__(self): |
177 + def __nonzero__(self): |
176 + return True |
178 + return True |
177 + |
179 + |
178 def __len__(self): |
180 def __len__(self): |
179 return constraints.MAX_FILE_SIZE + 1 |
181 return constraints.MAX_FILE_SIZE + 1 |
180 |
182 |
181 @@ -4537,6 +4543,9 @@ class TestObjectController(unittest.Test |
183 @@ -5134,6 +5140,9 @@ class TestObjectController(unittest.Test |
182 |
184 |
183 class LargeResponseBody(object): |
185 class LargeResponseBody(object): |
184 |
186 |
185 + def __nonzero__(self): |
187 + def __nonzero__(self): |
186 + return True |
188 + return True |