// Code generated by convertFourslash; DO NOT EDIT. // To modify this test, run "npm run makemanual genericCallsWithOptionalParams1" package fourslash_test import ( "testing" "github.com/microsoft/typescript-go/internal/fourslash" "github.com/microsoft/typescript-go/internal/testutil" ) func TestGenericCallsWithOptionalParams1(t *testing.T) { fourslash.SkipIfFailing(t) t.Parallel() defer testutil.RecoverAndFail(t, "Panic on fourslash test") const content = `class Collection { public add(x: T) { } } interface Utils { fold(c: Collection, folder: (s: S, t: T) => T, init?: S): T; } var c = new Collection(); var utils: Utils; var /*1*/r = utils.fold(c, (s, t) => t, ""); var /*2*/r2 = utils.fold(c, (s, t) => t);` f, done := fourslash.NewFourslash(t, nil /*capabilities*/, content) defer done() f.VerifyQuickInfoAt(t, "1", "var r: string", "") f.VerifyQuickInfoAt(t, "2", "var r2: string", "") }