test: add optional argument d.ts generation.

This commit is contained in:
Artem Kobzar
2022-01-24 15:45:12 +01:00
committed by Space
parent 0cf1ebd686
commit f835433221
2 changed files with 5 additions and 5 deletions
@@ -13,7 +13,7 @@ declare namespace JS_TESTS {
function varargWithOtherParameters(x: string, y: Array<string>, z: string): number;
function varargWithComplexType(x: Array<(p0: Array<Int32Array>) => Array<Int32Array>>): number;
function sumNullable(x: Nullable<number>, y: Nullable<number>): number;
function defaultParameters(x: number, y: string): string;
function defaultParameters(x?: number, y?: string): string;
function generic1<T>(x: T): T;
function generic2<T>(x: Nullable<T>): boolean;
function genericWithConstraint<T extends string>(x: T): T;
@@ -94,7 +94,7 @@ declare namespace JS_TESTS {
constructor(name: string);
get name(): string;
component1(): string;
copy(name: string): foo.TestDataClass;
copy(name?: string): foo.TestDataClass;
toString(): string;
hashCode(): number;
equals(other: Nullable<any>): boolean;
@@ -7,7 +7,7 @@ declare namespace JS_TESTS {
constructor(value: string);
get value(): string;
component1(): string;
copy(value: string): foo.bar.baz.C1;
copy(value?: string): foo.bar.baz.C1;
toString(): string;
hashCode(): number;
equals(other: Nullable<any>): boolean;
@@ -19,7 +19,7 @@ declare namespace JS_TESTS {
constructor(value: string);
get value(): string;
component1(): string;
copy(value: string): a.b.C2;
copy(value?: string): a.b.C2;
toString(): string;
hashCode(): number;
equals(other: Nullable<any>): boolean;
@@ -30,7 +30,7 @@ declare namespace JS_TESTS {
constructor(value: string);
get value(): string;
component1(): string;
copy(value: string): C3;
copy(value?: string): C3;
toString(): string;
hashCode(): number;
equals(other: Nullable<any>): boolean;