static bool test_wbc_pingdc(struct torture_context *tctx) { struct wbcInterfaceDetails *details; torture_assert_wbc_equal(tctx, wbcPingDc("random_string", NULL), WBC_ERR_DOMAIN_NOT_FOUND, "%s", "wbcPingDc failed"); torture_assert_wbc_ok(tctx, wbcPingDc(NULL, NULL), "%s", "wbcPingDc failed"); torture_assert_wbc_ok(tctx, wbcInterfaceDetails(&details), "%s", "wbcInterfaceDetails failed"); torture_assert(tctx, details, "wbcInterfaceDetails returned NULL pointer"); torture_assert(tctx, details->netbios_domain, "wbcInterfaceDetails returned NULL netbios_domain"); torture_assert_wbc_ok(tctx, wbcPingDc(details->netbios_domain, NULL), "wbcPingDc(%s) failed", details->netbios_domain); torture_assert_wbc_ok(tctx, wbcPingDc("BUILTIN", NULL), "%s", "wbcPingDc(BUILTIN) failed"); wbcFreeMemory(details); return true; }
static bool test_wbc_pingdc(struct torture_context *tctx) { torture_assert_wbc_equal(tctx, wbcPingDc("random_string", NULL), WBC_ERR_NOT_IMPLEMENTED, "wbcPingDc failed"); torture_assert_wbc_ok(tctx, wbcPingDc(NULL, NULL), "wbcPingDc failed"); return true; }