torture: desactivate the level 4 tests for DFS referral
authorMatthieu Patou <mat@matws.net>
Wed, 18 May 2011 04:44:05 +0000 (08:44 +0400)
committerMatthieu Patou <mat@samba.org>
Wed, 18 May 2011 11:04:00 +0000 (13:04 +0200)
Autobuild-User: Matthieu Patou <mat@samba.org>
Autobuild-Date: Wed May 18 13:04:00 CEST 2011 on sn-devel-104

source4/torture/dfs/domaindfs.c

index fafae179a3dfca6786a830a911776360247165f2..4914217e7a6c5789f226463fcbba8bf336fa2224 100644 (file)
@@ -380,7 +380,11 @@ static bool test_getsysvolreferral(struct torture_context *tctx,
                                                "Wrong DFS_path %s unable to find substring %s in it",
                                                resp3.referral_entries[0].referral.v3.referrals.r1.netw_address,
                                                str+1));
-
+#if 0
+       /*
+        * Due to strange behavior with XP and level 4
+        * we are obliged to degrade to level 3 ...
+        */
        r3.in.req.max_referral_level = 4;
 
        torture_assert_ntstatus_ok(tctx,
@@ -394,6 +398,17 @@ static bool test_getsysvolreferral(struct torture_context *tctx,
        torture_assert_int_equal(tctx, memcmp(resp3.referral_entries[0].referral.v3.service_site_guid.value, zeros, 16), 0,
                                 talloc_asprintf(tctx,
                                        "Service_site_guid is not NULL as expected"));
+#endif
+       r3.in.req.max_referral_level = 4;
+
+       torture_assert_ntstatus_ok(tctx,
+                  dfs_cli_do_call(cli->tree, &r3),
+                  "Get sysvol Domain referral failed");
+
+       torture_assert_int_equal(tctx, resp3.referral_entries[0].version, 3,
+                                talloc_asprintf(tctx,
+                                       "Not expected version for referral entry 0 got %d expected 3 in degraded mode",
+                                       resp3.referral_entries[0].version));
 #if 0
        /*
         * We do not support fallback indication for the moment
@@ -401,12 +416,12 @@ static bool test_getsysvolreferral(struct torture_context *tctx,
        torture_assert_int_equal(tctx, resp3.header_flags,
                                        DFS_HEADER_FLAG_STORAGE_SVR | DFS_HEADER_FLAG_TARGET_BCK,
                                        "Header flag different it's not a referral for a storage with fallback");
-#endif
        torture_assert_int_equal(tctx, resp3.referral_entries[0].referral.v4.entry_flags,
                                 DFS_FLAG_REFERRAL_FIRST_TARGET_SET,
                                 talloc_asprintf(tctx,
                                        "Wrong entry flag expected to have a non domain response and got %d",
                                        resp3.referral_entries[0].referral.v4.entry_flags));
+#endif
        return true;
 }