mirror of
https://github.com/ceph/s3-tests.git
synced 2024-11-21 23:29:47 +00:00
8186dd7561
Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit f5d0bc9be3
)
9 lines
399 B
Python
9 lines
399 B
Python
from . import utils
|
|
|
|
def test_generate():
|
|
FIVE_MB = 5 * 1024 * 1024
|
|
assert len(''.join(utils.generate_random(0))) == 0
|
|
assert len(''.join(utils.generate_random(1))) == 1
|
|
assert len(''.join(utils.generate_random(FIVE_MB - 1))) == FIVE_MB - 1
|
|
assert len(''.join(utils.generate_random(FIVE_MB))) == FIVE_MB
|
|
assert len(''.join(utils.generate_random(FIVE_MB + 1))) == FIVE_MB + 1
|