@adobe/data - v0.10.30
    Preparing search index...

    Function assertVersioning

    • The ONE co-located guard a versioned app writes — it runs BOTH checks so a single test proves the versioning is consistent end to end:

      1. assertVersionsMatchSchema — the history folds to the live schema, every change is recorded, only real persisted schemas appear, handlers are single-quadrant (schema/authoring coverage; throws synchronously with a fix recipe);
      2. testUpgradeHandlers — every entry with a handler has a handlers case, and each case runs against a store staged to the handler's input version and passes (handler coverage + behavior; throws for a missing case, rejects for a failing run).

      currentVersion is taken from database.version — so a bug wiring db.version to something other than entries.length - 1 is caught too.

      Returns the promise from step 2 — it("versioning", () => assertVersioning({ … })). The two underlying functions stay exported for bespoke use.

      Parameters

      • input: {
            database: VersionedDatabase;
            entries: readonly VersionEntry[];
            handlers?: Readonly<Record<number, UpgradeHandlerTest<any>>>;
        }

      Returns Promise<void>