diff --git a/modules/@angular/core/test/dom/shim_spec.ts b/modules/@angular/core/test/dom/shim_spec.ts index 735bf55993..870aef9f0e 100644 --- a/modules/@angular/core/test/dom/shim_spec.ts +++ b/modules/@angular/core/test/dom/shim_spec.ts @@ -13,12 +13,14 @@ export function main() { describe('Shim', () => { it('should provide correct function.name ', () => { - var functionWithoutName = function(_) {}; + var functionWithoutName = identity(() => function(_) {}); function foo(_){}; - expect((functionWithoutName).name).toEqual(''); + expect((functionWithoutName).name).toBeFalsy(); expect((foo).name).toEqual('foo'); }); }); } + +function identity(a) { return a; }