describe('Component vnRadio', () => { let $element; let $ctrl; let element; beforeEach(ngModule('vnCore')); beforeEach(inject(($compile, $rootScope) => { $element = $compile(` { $element.remove(); }); describe('field() setter', () => { it(`should change field value when clicked`, () => { element.click(); expect($ctrl.field).toEqual('myVal'); }); }); });