UNPKG

aurelia-orm

Version:

Makes working with entities and calling your Rest API simple.

12 lines (10 loc) 442 B
import {WithAssociations} from '../resources/entity/with-associations'; import {OrmMetadata} from '../../src/orm-metadata'; describe('@association()', function() { it('Should add associations on the entity (default and custom).', function() { expect(OrmMetadata.forTarget(WithAssociations).fetch('associations')).toEqual({ foo: {entity: 'foo', type: 'collection'}, bar: {entity: 'custom', type: 'entity'} }); }); });