Files
kjol/tools/tsgo/internal/fourslash/tests/gen/tsxRename4_test.go
2026-07-09 16:50:43 -04:00

36 lines
1.0 KiB
Go

// Code generated by convertFourslash; DO NOT EDIT.
// To modify this test, run "npm run makemanual tsxRename4"
package fourslash_test
import (
"testing"
"github.com/microsoft/typescript-go/internal/fourslash"
"github.com/microsoft/typescript-go/internal/testutil"
)
func TestTsxRename4(t *testing.T) {
fourslash.SkipIfFailing(t)
t.Parallel()
defer testutil.RecoverAndFail(t, "Panic on fourslash test")
const content = `// @jsx: preserve
//@Filename: file.tsx
declare namespace JSX {
interface Element {}
interface IntrinsicElements {
div: {};
}
}
[|class [|{| "contextRangeIndex": 0 |}MyClass|] {}|]
[|<[|{| "contextRangeIndex": 2 |}MyClass|]></[|{| "contextRangeIndex": 2 |}MyClass|]>|];
[|<[|{| "contextRangeIndex": 5 |}MyClass|]/>|];
[|<[|{| "contextRangeIndex": 7 |}div|]> </[|{| "contextRangeIndex": 7 |}div|]>|]`
f, done := fourslash.NewFourslash(t, nil /*capabilities*/, content)
defer done()
f.VerifyNoErrors(t)
f.VerifyBaselineRenameAtRangesWithText(t, nil /*preferences*/, "MyClass", "div")
}