"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const core_1 = require("@vived/core");
const UC_1 = require("../UC");
const calloutFactory_1 = require("./calloutFactory");
describe("Setup Callouts", () => {
    it("Sets up Look At Camera UC by default", () => {
        const appObjects = (0, core_1.makeAppObjectRepo)();
        const factory = (0, calloutFactory_1.makeCalloutFactory)(appObjects);
        const calloutAO = factory("someCalloutID").appObject;
        expect(calloutAO.hasComponent(UC_1.LookAtCameraUC.type)).toBe(true);
    });
    it("Uses the look at factory if it is passed in", () => {
        const appObjects = (0, core_1.makeAppObjectRepo)();
        const lookAtCameraFactory = jest.fn();
        const factory = (0, calloutFactory_1.makeCalloutFactory)(appObjects, { lookAtCameraFactory });
        const calloutAO = factory("someCalloutID").appObject;
        expect(lookAtCameraFactory).toHaveBeenCalledWith(calloutAO);
        expect(calloutAO.hasComponent(UC_1.LookAtCameraUC.type)).toBe(false); // Proves the default factory was not called
    });
});
//# sourceMappingURL=calloutFactory.test.js.map