mirror of
https://github.com/psy0rz/zfs_autobackup.git
synced 2025-06-05 01:33:00 +03:00
better output to fixed progress test
This commit is contained in:
parent
b115f4b081
commit
4c5339dedd
@ -886,7 +886,7 @@ test_target1/test_source2/fs2/sub@test-20101111000003
|
|||||||
r=shelltest("dd if=/dev/zero of=/test_source1/data.txt bs=200000 count=1")
|
r=shelltest("dd if=/dev/zero of=/test_source1/data.txt bs=200000 count=1")
|
||||||
r = shelltest("zfs snapshot test_source1@test")
|
r = shelltest("zfs snapshot test_source1@test")
|
||||||
|
|
||||||
l=LogConsole(show_verbose=True, show_debug=False, color=False)
|
l=LogConsole(show_verbose=True, show_debug=True, color=False)
|
||||||
n=ZfsNode(utc=False, snapshot_time_format="bla", hold_name="bla", logger=l)
|
n=ZfsNode(utc=False, snapshot_time_format="bla", hold_name="bla", logger=l)
|
||||||
d=ZfsDataset(n,"test_source1@test")
|
d=ZfsDataset(n,"test_source1@test")
|
||||||
|
|
||||||
@ -896,10 +896,10 @@ test_target1/test_source2/fs2/sub@test-20101111000003
|
|||||||
with OutputIO() as buf:
|
with OutputIO() as buf:
|
||||||
with redirect_stderr(buf):
|
with redirect_stderr(buf):
|
||||||
try:
|
try:
|
||||||
n.run(["sleep", "10"], inp=sp)
|
n.run(["sleep", "3"], inp=sp)
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
print(buf.getvalue())
|
print(list(buf.getvalue()))
|
||||||
# correct message?
|
# correct message?
|
||||||
self.assertRegex(buf.getvalue(),".*>>> .*minutes left.*")
|
self.assertRegex(buf.getvalue(),".*>>> .*minutes left.*")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user