#include "includes.h"
#include "lib/events/events.h"
-#include "lib/ldb/include/ldb.h"
-#include "lib/ldb/include/ldb_errors.h"
+#include <ldb.h>
+#include <ldb_errors.h>
#include "lib/ldb-samba/ldif_handlers.h"
#include "ldb_wrap.h"
#include "dsdb/samdb/samdb.h"
ldif = ldb_ldif_read_string(ldb, &ldif_str);
torture_assert(tctx, ldif, "Failed to parse LDIF for authOrig");
- werr = dsdb_attribute_from_ldb(ldb, schema, ldif->msg);
+ werr = dsdb_set_attribute_from_ldb(ldb, schema, ldif->msg);
ldb_ldif_read_free(ldb, ldif);
- torture_assert_werr_ok(tctx, werr, "dsdb_attribute_from_ldb() failed!");
+ torture_assert_werr_ok(tctx, werr, "dsdb_set_attribute_from_ldb() failed!");
- ldb_res = dsdb_set_schema(ldb, schema);
+ ldb_res = dsdb_set_schema(ldb, schema, SCHEMA_WRITE);
torture_assert_int_equal(tctx, ldb_res, LDB_SUCCESS, "dsdb_set_schema() failed");
return true;
priv = talloc_zero(tctx, struct torture_dsdb_syntax);
torture_assert(tctx, priv, "No memory");
- priv->ldb = provision_get_schema(priv, tctx->lp_ctx, NULL);
+ priv->ldb = provision_get_schema(priv, tctx->lp_ctx, NULL, NULL);
torture_assert(tctx, priv->ldb, "Failed to load schema from disk");
priv->schema = dsdb_get_schema(priv->ldb, NULL);
struct torture_dsdb_syntax *priv;
priv = talloc_get_type_abort(data, struct torture_dsdb_syntax);
+ talloc_unlink(priv, priv->ldb);
talloc_free(priv);
return true;
typedef bool (*pfn_run)(struct torture_context *, void *);
struct torture_tcase *tc;
- struct torture_suite *suite = torture_suite_create(mem_ctx, "DSDB-SYNTAX");
+ struct torture_suite *suite = torture_suite_create(mem_ctx, "dsdb.syntax");
if (suite == NULL) {
return NULL;