Files
tsgo/internal/fourslash/tests/gen/findAllRefsForImportCall_test.go

33 lines
1003 B
Go

// Code generated by convertFourslash; DO NOT EDIT.
// To modify this test, run "npm run makemanual findAllRefsForImportCall"
package fourslash_test
import (
"testing"
"github.com/microsoft/typescript-go/internal/fourslash"
"github.com/microsoft/typescript-go/internal/testutil"
)
func TestFindAllRefsForImportCall(t *testing.T) {
fourslash.SkipIfFailing(t)
t.Parallel()
defer testutil.RecoverAndFail(t, "Panic on fourslash test")
const content = `// @Filename: /app.ts
export function he/**/llo() {};
// @Filename: /re-export.ts
export const services = { app: setup(() => import('./app')) }
function setup<T>(importee: () => Promise<T>): T { return {} as any }
// @Filename: /indirect-use.ts
import("./re-export").then(mod => mod.services.app.hello());
// @Filename: /direct-use.ts
async function main() {
const mod = await import("./app")
mod.hello();
}`
f, done := fourslash.NewFourslash(t, nil /*capabilities*/, content)
defer done()
f.VerifyBaselineFindAllReferences(t, "")
}