test(compiler): remove whitespace in spans (#36169)

https://github.com/angular/angular/pull/36133 and https://github.com/angular/angular/pull/35986
caused a conflict in test after they both got merged to master.
This PR fixes the failed tests.

PR Close #36169
This commit is contained in:
Keen Yee Liau 2020-03-20 11:16:36 -07:00 committed by Misko Hevery
parent d714b95fb9
commit ae3eaf8b16
1 changed files with 2 additions and 2 deletions

View File

@ -245,7 +245,7 @@ describe('R3 AST source spans', () => {
// </ng-template> // </ng-template>
expectFromHtml('<div *ngFor="item of items"></div>').toEqual([ expectFromHtml('<div *ngFor="item of items"></div>').toEqual([
['Template', '0:28', '0:28', '28:34'], ['Template', '0:28', '0:28', '28:34'],
['BoundAttribute', '5:27', '13:18'], // ngFor="item of items" -> item ['BoundAttribute', '5:27', '13:17'], // ngFor="item of items" -> item
['BoundAttribute', '5:27', '21:26'], // ngFor="item of items" -> items ['BoundAttribute', '5:27', '21:26'], // ngFor="item of items" -> items
['Element', '0:34', '0:28', '28:34'], ['Element', '0:34', '0:28', '28:34'],
]); ]);
@ -263,7 +263,7 @@ describe('R3 AST source spans', () => {
it('is correct for variables via as ...', () => { it('is correct for variables via as ...', () => {
expectFromHtml('<div *ngIf="expr as local"></div>').toEqual([ expectFromHtml('<div *ngIf="expr as local"></div>').toEqual([
['Template', '0:27', '0:27', '27:33'], ['Template', '0:27', '0:27', '27:33'],
['BoundAttribute', '5:26', '12:17'], // ngIf="expr as local" -> expr ['BoundAttribute', '5:26', '12:16'], // ngIf="expr as local" -> expr
['Variable', '6:25', '6:10'], // ngIf="expr as local -> ngIf ['Variable', '6:25', '6:10'], // ngIf="expr as local -> ngIf
['Element', '0:33', '0:27', '27:33'], ['Element', '0:33', '0:27', '27:33'],
]); ]);