From deba880986b1029fa059fcfba9b2a72abf598a9b Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Wed, 4 May 2011 17:45:34 +0200 Subject: s3-torture: Add a test for notify upon read&x This makes sure that when a file is brought online by a read call we notify the client for FILE_NOTIFY_CHANGE_ATTRIBUTES. Autobuild-User: Volker Lendecke Autobuild-Date: Wed May 4 21:09:22 CEST 2011 on sn-devel-104 --- source3/torture/torture.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'source3/torture/torture.c') diff --git a/source3/torture/torture.c b/source3/torture/torture.c index 5dfcb7e97c..fa54f605f4 100644 --- a/source3/torture/torture.c +++ b/source3/torture/torture.c @@ -58,6 +58,7 @@ static bool use_multishare_conn = False; static bool do_encrypt; static const char *local_path = NULL; static int signing_state = Undefined; +char *test_filename; bool torture_showall = False; @@ -8374,6 +8375,7 @@ static struct { { "NOTIFY-BENCH", run_notify_bench }, { "BAD-NBT-SESSION", run_bad_nbt_session }, { "SMB-ANY-CONNECT", run_smb_any_connect }, + { "NOTIFY-ONLINE", run_notify_online }, { "LOCAL-SUBSTITUTE", run_local_substitute, 0}, { "LOCAL-GENCACHE", run_local_gencache, 0}, { "LOCAL-TALLOC-DICT", run_local_talloc_dict, 0}, @@ -8467,6 +8469,7 @@ static void usage(void) printf("\t-p port\n"); printf("\t-s seed\n"); printf("\t-b unclist_filename specify multiple shares for multiple connections\n"); + printf("\t-f filename filename to test\n"); printf("\n\n"); printf("tests are:"); @@ -8544,7 +8547,8 @@ static void usage(void) fstrcpy(workgroup, lp_workgroup()); - while ((opt = getopt(argc, argv, "p:hW:U:n:N:O:o:m:Ll:d:Aec:ks:b:B:")) != EOF) { + while ((opt = getopt(argc, argv, "p:hW:U:n:N:O:o:m:Ll:d:Aec:ks:b:B:f:")) + != EOF) { switch (opt) { case 'p': port_to_use = atoi(optarg); @@ -8613,6 +8617,9 @@ static void usage(void) case 'B': torture_blocksize = atoi(optarg); break; + case 'f': + test_filename = SMB_STRDUP(optarg); + break; default: printf("Unknown option %c (%d)\n", (char)opt, opt); usage(); -- cgit