"use strict";
/*!
 * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
 * Licensed under the MIT License.
 */
Object.defineProperty(exports, "__esModule", { value: true });
const node_assert_1 = require("node:assert");
const internal_1 = require("@fluidframework/container-definitions/internal");
const internal_2 = require("@fluidframework/telemetry-utils/internal");
const dataStoreRegistry_js_1 = require("../dataStoreRegistry.js");
describe("Data Store Registry Creation Tests", () => {
    // Define two entries with the same name
    const defaultName = "default";
    const entries = [
        [defaultName, []],
        [defaultName, []],
    ];
    it("Validate duplicate name entries", () => {
        try {
            new dataStoreRegistry_js_1.FluidDataStoreRegistry(entries);
            node_assert_1.strict.fail();
        }
        catch (error) {
            (0, node_assert_1.strict)((0, internal_2.isFluidError)(error));
            node_assert_1.strict.strictEqual(error.errorType, internal_1.ContainerErrorTypes.usageError);
            node_assert_1.strict.strictEqual(error.message, "Duplicate entry names exist");
        }
    });
});
//# sourceMappingURL=dataStoreRegistry.spec.js.map