diff options
author | Tim Burke <tim.burke@gmail.com> | 2023-02-02 15:33:54 -0800 |
---|---|---|
committer | Tim Burke <tim.burke@gmail.com> | 2023-02-02 15:34:00 -0800 |
commit | 488f8c839f034172d20b3f28ca851d83b7a3bfff (patch) | |
tree | 630befca0976a220dca56750295f078387f0c6ed /test/functional/test_account.py | |
parent | 65fd75f710d2c9e5992fdb226b28b6655609bf07 (diff) | |
download | swift-488f8c839f034172d20b3f28ca851d83b7a3bfff.tar.gz |
tests: Fix some func tests to do with metadata maximums
Previously, if a cluster's combined configured max_meta_name_length and
max_meta_value_length constraints were larger than the configured
max_meta_overall_size, we would accidentally go over the overall size
while intending to just test being exactly at the value length-limit.
Change-Id: I42a5287011509e5b43959aab060f9ec7405ae5b9
Diffstat (limited to 'test/functional/test_account.py')
-rw-r--r-- | test/functional/test_account.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/functional/test_account.py b/test/functional/test_account.py index b4598dd08..6cf30968d 100644 --- a/test/functional/test_account.py +++ b/test/functional/test_account.py @@ -796,6 +796,14 @@ class TestAccount(unittest.TestCase): 'k' * self.max_meta_name_length): 'v'}) resp.read() self.assertEqual(resp.status, 204) + # Clear it, so the value-length checking doesn't accidentally trip + # the overall max + resp = retry(post, + {'X-Account-Meta-' + ( + 'k' * self.max_meta_name_length): ''}) + resp.read() + self.assertEqual(resp.status, 204) + resp = retry( post, {'X-Account-Meta-' + ('k' * ( |