vendor tsgo
This commit is contained in:
@@ -0,0 +1,55 @@
|
||||
// Code generated by convertFourslash; DO NOT EDIT.
|
||||
// To modify this test, run "npm run makemanual docCommentTemplateObjectLiteralMethods01"
|
||||
|
||||
package fourslash_test
|
||||
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/microsoft/typescript-go/internal/fourslash"
|
||||
"github.com/microsoft/typescript-go/internal/testutil"
|
||||
)
|
||||
|
||||
func TestDocCommentTemplateObjectLiteralMethods01(t *testing.T) {
|
||||
fourslash.SkipIfFailing(t)
|
||||
t.Parallel()
|
||||
defer testutil.RecoverAndFail(t, "Panic on fourslash test")
|
||||
const content = `var x = {
|
||||
/*0*/
|
||||
foo() {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
/*1*/
|
||||
[1 + 2 + 3 + Math.rand()](x: number, y: string, z = true) { }
|
||||
|
||||
/*2*/
|
||||
m1: function(a) {}
|
||||
|
||||
/*3*/
|
||||
m2: (a: string, b: string) => {}
|
||||
}`
|
||||
capabilities := fourslash.GetDefaultCapabilities()
|
||||
capabilities.TextDocument.Completion.CompletionItem.SnippetSupport = new(false)
|
||||
f, done := fourslash.NewFourslash(t, capabilities, content)
|
||||
defer done()
|
||||
f.VerifyJSDocCompletion(t, "0", 11, `/**
|
||||
*
|
||||
* @returns
|
||||
*/`, nil)
|
||||
f.VerifyJSDocCompletion(t, "1", 11, `/**
|
||||
*
|
||||
* @param x
|
||||
* @param y
|
||||
* @param z
|
||||
*/`, nil)
|
||||
f.VerifyJSDocCompletion(t, "2", 11, `/**
|
||||
*
|
||||
* @param a
|
||||
*/`, nil)
|
||||
f.VerifyJSDocCompletion(t, "3", 11, `/**
|
||||
*
|
||||
* @param a
|
||||
* @param b
|
||||
*/`, nil)
|
||||
}
|
||||
Reference in New Issue
Block a user