Allow blocksize to be changed in Environment

This number is peppered all over the test suite, so changing @blocksize
for everything is not a goer, when we really only need to change it for
one test.
This commit is contained in:
Patrick J Cherry
2018-02-06 09:55:32 +00:00
parent 7704f9e5c8
commit da35187af0
3 changed files with 11 additions and 5 deletions

View File

@@ -119,6 +119,10 @@ class TestServeMode < Test::Unit::TestCase
def test_write_with_fua_is_accepted
page_size = Integer(`getconf PAGESIZE`)
@env = Environment.new
@env.blocksize = page_size * 10
@env.writefile1('0')
@env.serve1
connect_to_server do |client|
# Write somewhere in the third page
pos = page_size * 3 + 100