import { OrbitControls } from 'three/examples/jsm/controls/OrbitControls' import { describe, test, expect } from 'vitest' import { useCatalog } from './useCatalog' describe('useCatalog()', () => { test('should init catalog', () => { const { catalogue } = useCatalog() expect(catalogue).toHaveProperty('Mesh') }) test('should be able to extend catalogue', () => { const { catalogue, extend } = useCatalog() extend({ OrbitControls }) expect(catalogue).toHaveProperty('OrbitControls') }) test('catalog objects should be instanciable', () => { const { catalogue } = useCatalog() expect(new catalogue.PerspectiveCamera()).toHaveProperty('type', 'PerspectiveCamera') }) })