UNPKG

aurelia-orm

Version:

Makes working with entities and calling your Rest API simple.

11 lines (9 loc) 528 B
import {WithResource} from '../resources/entity/with-resource'; import {WithCustomRepository} from '../resources/entity/with-custom-repository'; import {OrmMetadata} from '../../src/orm-metadata'; describe('@association()', function() { it('Should add associations on the entity (default and custom).', function() { expect(OrmMetadata.forTarget(WithResource).fetch('resource')).toEqual('with-resource'); expect(OrmMetadata.forTarget(WithCustomRepository).fetch('resource')).toEqual('withcustomrepository'); }); });