@@ -10482,7 +10482,6 @@ runInEachFileSystem((os: string) => {
1048210482 const dtsContents = env . getContents ( 'test.d.ts' ) ;
1048310483
1048410484 expect ( jsContents ) . toContain ( 'inputs: { value: [2, "value", "value", toNumber] }' ) ;
10485- expect ( jsContents ) . toContain ( 'features: [i0.ɵɵInputTransformsFeature]' ) ;
1048610485 expect ( dtsContents ) . toContain ( 'static ngAcceptInputType_value: boolean | string;' ) ;
1048710486 } ) ;
1048810487
@@ -10507,7 +10506,6 @@ runInEachFileSystem((os: string) => {
1050710506 const dtsContents = env . getContents ( 'test.d.ts' ) ;
1050810507
1050910508 expect ( jsContents ) . toContain ( 'inputs: { value: [2, "value", "value", toNumber] }' ) ;
10510- expect ( jsContents ) . toContain ( 'features: [i0.ɵɵInputTransformsFeature]' ) ;
1051110509 expect ( dtsContents ) . toContain ( 'static ngAcceptInputType_value: boolean | string;' ) ;
1051210510 } ) ;
1051310511
@@ -10541,7 +10539,6 @@ runInEachFileSystem((os: string) => {
1054110539 const dtsContents = env . getContents ( 'test.d.ts' ) ;
1054210540
1054310541 expect ( jsContents ) . toContain ( 'inputs: { value: [2, "value", "value", toNumber] }' ) ;
10544- expect ( jsContents ) . toContain ( 'features: [i0.ɵɵInputTransformsFeature]' ) ;
1054510542 expect ( dtsContents ) . toContain ( 'import * as i1 from "./types"' ) ;
1054610543 expect ( dtsContents ) . toContain (
1054710544 'static ngAcceptInputType_value: boolean | string | i1.GenericWrapper<string>;' ,
@@ -10588,7 +10585,6 @@ runInEachFileSystem((os: string) => {
1058810585 const dtsContents = env . getContents ( 'test.d.ts' ) ;
1058910586
1059010587 expect ( jsContents ) . toContain ( 'inputs: { value: [2, "value", "value", toNumber] }' ) ;
10591- expect ( jsContents ) . toContain ( 'features: [i0.ɵɵInputTransformsFeature]' ) ;
1059210588 expect ( dtsContents ) . toContain ( 'import * as i1 from "./types"' ) ;
1059310589 expect ( dtsContents ) . toContain ( 'import * as i2 from "./other-types"' ) ;
1059410590 expect ( dtsContents ) . toContain (
@@ -10630,7 +10626,6 @@ runInEachFileSystem((os: string) => {
1063010626
1063110627 expect ( jsContents ) . toContain ( `import { externalToNumber } from 'external';` ) ;
1063210628 expect ( jsContents ) . toContain ( 'inputs: { value: [2, "value", "value", externalToNumber] }' ) ;
10633- expect ( jsContents ) . toContain ( 'features: [i0.ɵɵInputTransformsFeature]' ) ;
1063410629 expect ( dtsContents ) . toContain ( 'import * as i1 from "external";' ) ;
1063510630 expect ( dtsContents ) . toContain ( 'static ngAcceptInputType_value: i1.ExternalToNumberType;' ) ;
1063610631 } ) ;
@@ -10668,7 +10663,6 @@ runInEachFileSystem((os: string) => {
1066810663 expect ( jsContents ) . toContain (
1066910664 'inputs: { value: [2, "value", "value", (value) => value ? 1 : 0] }' ,
1067010665 ) ;
10671- expect ( jsContents ) . toContain ( 'features: [i0.ɵɵInputTransformsFeature]' ) ;
1067210666 expect ( dtsContents ) . toContain ( 'import * as i1 from "external";' ) ;
1067310667 expect ( dtsContents ) . toContain ( 'static ngAcceptInputType_value: i1.ExternalToNumberType;' ) ;
1067410668 } ) ;
@@ -10701,7 +10695,6 @@ runInEachFileSystem((os: string) => {
1070110695 const dtsContents = env . getContents ( 'test.d.ts' ) ;
1070210696
1070310697 expect ( jsContents ) . toContain ( 'inputs: { value: [2, "value", "value", toBoolean] }' ) ;
10704- expect ( jsContents ) . toContain ( 'features: [i0.ɵɵInputTransformsFeature]' ) ;
1070510698 expect ( dtsContents ) . toContain (
1070610699 `static ngAcceptInputType_value: boolean | "" | "true" | "false";` ,
1070710700 ) ;
@@ -10728,7 +10721,6 @@ runInEachFileSystem((os: string) => {
1072810721 const dtsContents = env . getContents ( 'test.d.ts' ) ;
1072910722
1073010723 expect ( jsContents ) . toContain ( 'inputs: { value: [2, "value", "value", toNumber] }' ) ;
10731- expect ( jsContents ) . toContain ( 'features: [i0.ɵɵInputTransformsFeature]' ) ;
1073210724 expect ( dtsContents ) . toContain ( 'static ngAcceptInputType_value: boolean | string;' ) ;
1073310725 } ) ;
1073410726
@@ -10753,40 +10745,9 @@ runInEachFileSystem((os: string) => {
1075310745 const dtsContents = env . getContents ( 'test.d.ts' ) ;
1075410746
1075510747 expect ( jsContents ) . toContain ( 'inputs: { value: [2, "value", "value", toNumber] }' ) ;
10756- expect ( jsContents ) . toContain ( 'features: [i0.ɵɵInputTransformsFeature]' ) ;
1075710748 expect ( dtsContents ) . toContain ( 'static ngAcceptInputType_value: unknown;' ) ;
1075810749 } ) ;
1075910750
10760- it ( 'should insert the InputTransformsFeature before the InheritDefinitionFeature' , ( ) => {
10761- env . write (
10762- '/test.ts' ,
10763- `
10764- import {Directive, Input} from '@angular/core';
10765-
10766- function toNumber(value: boolean | string) { return 1; }
10767-
10768- @Directive()
10769- export class ParentDir {}
10770-
10771- @Directive()
10772- export class Dir extends ParentDir {
10773- @Input({transform: toNumber}) value!: number;
10774- }
10775- ` ,
10776- ) ;
10777-
10778- env . driveMain ( ) ;
10779-
10780- const jsContents = env . getContents ( 'test.js' ) ;
10781- const dtsContents = env . getContents ( 'test.d.ts' ) ;
10782-
10783- expect ( jsContents ) . toContain ( 'inputs: { value: [2, "value", "value", toNumber] }' ) ;
10784- expect ( jsContents ) . toContain (
10785- 'features: [i0.ɵɵInputTransformsFeature, i0.ɵɵInheritDefinitionFeature]' ,
10786- ) ;
10787- expect ( dtsContents ) . toContain ( 'static ngAcceptInputType_value: boolean | string;' ) ;
10788- } ) ;
10789-
1079010751 it ( 'should compile an input with using an ambient type in the transform function' , ( ) => {
1079110752 env . write (
1079210753 'node_modules/external/index.d.ts' ,
@@ -10818,7 +10779,6 @@ runInEachFileSystem((os: string) => {
1081810779 expect ( jsContents ) . toContain (
1081910780 'inputs: { element: [2, "element", "element", coerceElement] }' ,
1082010781 ) ;
10821- expect ( jsContents ) . toContain ( 'features: [i0.ɵɵInputTransformsFeature]' ) ;
1082210782 expect ( dtsContents ) . toContain (
1082310783 'static ngAcceptInputType_element: HTMLElement | i0.ElementRef<HTMLElement>;' ,
1082410784 ) ;
0 commit comments