From 0a8b3816f75b7ccf2301621fee0d26addded3033 Mon Sep 17 00:00:00 2001 From: Pawel Kozlowski Date: Thu, 23 Jul 2015 17:43:45 +0200 Subject: [PATCH] style(lexer): idiomatic TypeScript Closes #3228 --- modules/angular2/test/change_detection/parser/lexer_spec.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/angular2/test/change_detection/parser/lexer_spec.ts b/modules/angular2/test/change_detection/parser/lexer_spec.ts index db3805681c..c852d40861 100644 --- a/modules/angular2/test/change_detection/parser/lexer_spec.ts +++ b/modules/angular2/test/change_detection/parser/lexer_spec.ts @@ -217,10 +217,10 @@ export function main() { }); it('should throws exception for invalid exponent', function() { - expect(function() { lex("0.5E-"); }) + expect(() => { lex("0.5E-"); }) .toThrowError('Lexer Error: Invalid exponent at column 4 in expression [0.5E-]'); - expect(function() { lex("0.5E-A"); }) + expect(() => { lex("0.5E-A"); }) .toThrowError('Lexer Error: Invalid exponent at column 4 in expression [0.5E-A]'); }); @@ -230,7 +230,7 @@ export function main() { }); it('should throw error on invalid unicode', function() { - expect(function() { lex("'\\u1''bla'"); }) + expect(() => { lex("'\\u1''bla'"); }) .toThrowError( "Lexer Error: Invalid unicode escape [\\u1''b] at column 2 in expression ['\\u1''bla']"); });