Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/compiler/src/identifiers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ export class Identifiers {
name: 'ɵinlineInterpolate',
moduleName: CORE,
};
static interpolate: o.ExternalReference = {name: 'ɵɵinterpolate', moduleName: CORE};
static interpolate: o.ExternalReference = {name: 'ɵinterpolate', moduleName: CORE};
static EMPTY_ARRAY: o.ExternalReference = {name: 'ɵEMPTY_ARRAY', moduleName: CORE};
static EMPTY_MAP: o.ExternalReference = {name: 'ɵEMPTY_MAP', moduleName: CORE};
static Renderer: o.ExternalReference = {name: 'Renderer', moduleName: CORE};
Expand Down
18 changes: 18 additions & 0 deletions packages/core/test/acceptance/properties_spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -212,4 +212,22 @@ describe('property instructions', () => {

expect(img.src.indexOf('unsafe:')).toBe(0);
});

it('should handle interpolations with 10+ values', () => {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kara test description says 10+ values, but only checks for exactly 10 values.

@Component({
selector: 'app-comp',
template: `
<a href="http://g.com/?one={{'1'}}&two={{'2'}}&three={{'3'}}&four={{'4'}}&five={{'5'}}&six={{'6'}}&seven={{'7'}}&eight={{'8'}}&nine={{'9'}}&ten={{'10'}}">link2</a>`
})
class AppComp {
}

TestBed.configureTestingModule({declarations: [AppComp]});
const fixture = TestBed.createComponent(AppComp);
fixture.detectChanges();
const anchor = fixture.debugElement.query(By.css('a')).nativeElement;
expect(anchor.getAttribute('href'))
.toEqual(
`http://g.com/?one=1&two=2&three=3&four=4&five=5&six=6&seven=7&eight=8&nine=9&ten=10`);
});
});