mirror of
https://github.com/samba-team/samba.git
synced 2025-03-27 22:50:26 +03:00
s4:torture:basic: use assert in the second loop in delayed_write_update1b
We can hence replace the assert after the loop by a success torture_comment. Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
parent
08432cd88f
commit
2907950f13
@ -556,22 +556,21 @@ static bool test_delayed_write_update1b(struct torture_context *tctx, struct smb
|
||||
|
||||
torture_comment(tctx, "write time %s\n",
|
||||
nt_time_string(tctx, finfo3.all_info.out.write_time));
|
||||
if (finfo2.all_info.out.write_time != finfo3.all_info.out.write_time) {
|
||||
double diff = timeval_elapsed(&start);
|
||||
|
||||
torture_comment(tctx, "server updated write_time after %.2f seconds"
|
||||
"(write time update delay == %.2f)(correct)\n",
|
||||
diff, used_delay / (double)1000000);
|
||||
break;
|
||||
}
|
||||
torture_assert_u64_equal(tctx,
|
||||
finfo3.all_info.out.write_time,
|
||||
finfo2.all_info.out.write_time,
|
||||
talloc_asprintf(tctx,
|
||||
"Server updated write time "
|
||||
"after %.2f seconds (wrong!)",
|
||||
timeval_elapsed(&start)));
|
||||
|
||||
fflush(stdout);
|
||||
smb_msleep(1 * msec);
|
||||
}
|
||||
|
||||
torture_assert_u64_equal(tctx,
|
||||
finfo3.all_info.out.write_time,
|
||||
finfo2.all_info.out.write_time,
|
||||
"Server updated write time");
|
||||
torture_comment(tctx, "Server did not update write time within 10 "
|
||||
"seconds. Good!\n");
|
||||
|
||||
/* the close should trigger an write time update */
|
||||
smbcli_close(cli->tree, fnum1);
|
||||
|
Loading…
x
Reference in New Issue
Block a user