+ torture_assert_int_equal(tctx, lpcfg_security(lp_ctx), SEC_ADS, "security should be ADS");
+ return true;
+}
+
+static bool test_server_role_member_specified2(struct torture_context *tctx)
+{
+ struct loadparm_context *lp_ctx = loadparm_init(tctx);
+ torture_assert(tctx, lpcfg_set_option(lp_ctx, "server role=member"), "lpcfg_set_option failed");
+ torture_assert(tctx, lpcfg_set_option(lp_ctx, "security=domain"), "lpcfg_set_option failed");
+ torture_assert_int_equal(tctx, lpcfg_server_role(lp_ctx), ROLE_DOMAIN_MEMBER, "ROLE should be member");
+ torture_assert_int_equal(tctx, lpcfg_security(lp_ctx), SEC_DOMAIN, "security should be domain");
+ return true;
+}
+
+static bool test_server_role_member_specified3(struct torture_context *tctx)
+{
+ struct loadparm_context *lp_ctx = loadparm_init(tctx);
+ torture_assert(tctx, lpcfg_set_option(lp_ctx, "server role=member"), "lpcfg_set_option failed");
+ torture_assert(tctx, lpcfg_set_option(lp_ctx, "security=ads"), "lpcfg_set_option failed");
+ torture_assert_int_equal(tctx, lpcfg_server_role(lp_ctx), ROLE_DOMAIN_MEMBER, "ROLE should be member");
+ torture_assert_int_equal(tctx, lpcfg_security(lp_ctx), SEC_ADS, "security should be ads");
+ return true;
+}
+
+static bool test_server_role_standalone_specified(struct torture_context *tctx)
+{
+ struct loadparm_context *lp_ctx = loadparm_init(tctx);
+ torture_assert(tctx, lpcfg_set_option(lp_ctx, "server role=standalone"), "lpcfg_set_option failed");
+ torture_assert_int_equal(tctx, lpcfg_server_role(lp_ctx), ROLE_STANDALONE, "ROLE should be standalone");
+ torture_assert_int_equal(tctx, lpcfg_security(lp_ctx), SEC_USER, "security should be USER");