Skip to content

Commit d186f75

Browse files
committed
DAOS-16686 utils: Remove all pre-read checks from NLT
These need to be reworked to be less fragile. Signed-off-by: Michael MacDonald <mjmac@google.com>
1 parent 59bd431 commit d186f75

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

utils/node_local_test.py

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
"""Node local test (NLT).
33
44
(C) Copyright 2020-2025 Intel Corporation.
5+
(C) Copyright 2025 Google LLC
56
67
SPDX-License-Identifier: BSD-2-Clause-Patent
78
@@ -2354,24 +2355,16 @@ def test_pre_read(self):
23542355
# Open a file and read in one go.
23552356
with open(join(dfuse.dir, 'file0'), 'r') as fd:
23562357
data0 = fd.read()
2357-
res = dfuse.check_usage()
2358-
assert res['statistics']['pre_read'] == 1, res
23592358

23602359
# Open a file and read in one go.
23612360
with open(join(dfuse.dir, 'file1'), 'r') as fd:
23622361
data1 = fd.read(16)
2363-
res = dfuse.check_usage(old=res)
2364-
assert res['statistics']['pre_read'] == 1, res
23652362

23662363
# Open a file and read two bytes at a time. Despite disabling buffering python will try and
23672364
# read a whole page the first time.
23682365
fd = os.open(join(dfuse.dir, 'file2'), os.O_RDONLY)
23692366
data2 = os.read(fd, 2)
2370-
res = dfuse.check_usage(old=res)
2371-
assert res['statistics']['pre_read'] == 1, res
23722367
_ = os.read(fd, 2)
2373-
res = dfuse.check_usage(old=res)
2374-
assert res['statistics']['pre_read'] == 0, res
23752368
os.close(fd)
23762369

23772370
# Open a MB file. This reads 8 128k chunks and 1 EOF.

0 commit comments

Comments
 (0)