Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove goto- prefix on testdata files #174

Merged
merged 1 commit into from
Dec 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions pkg/server/completion_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "autocomplete through binary",
filename: "testdata/goto-basic-object.jsonnet",
filename: "testdata/basic-object.jsonnet",
replaceString: "bar: 'foo',",
replaceByString: "bar: self.",
expected: protocol.CompletionList{
Expand All @@ -216,7 +216,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "autocomplete locals",
filename: "testdata/goto-basic-object.jsonnet",
filename: "testdata/basic-object.jsonnet",
replaceString: "bar: 'foo',",
replaceByString: "bar: ",
expected: protocol.CompletionList{
Expand All @@ -234,7 +234,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "autocomplete locals: good prefix",
filename: "testdata/goto-basic-object.jsonnet",
filename: "testdata/basic-object.jsonnet",
replaceString: "bar: 'foo',",
replaceByString: "bar: some",
expected: protocol.CompletionList{
Expand All @@ -252,7 +252,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "autocomplete locals: bad prefix",
filename: "testdata/goto-basic-object.jsonnet",
filename: "testdata/basic-object.jsonnet",
replaceString: "bar: 'foo',",
replaceByString: "bar: bad",
expected: protocol.CompletionList{
Expand All @@ -262,7 +262,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "autocomplete through import",
filename: "testdata/goto-imported-file.jsonnet",
filename: "testdata/imported-file.jsonnet",
replaceString: "b: otherfile.bar,",
replaceByString: "b: otherfile.",
expected: protocol.CompletionList{
Expand Down Expand Up @@ -291,7 +291,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "autocomplete through import with prefix",
filename: "testdata/goto-imported-file.jsonnet",
filename: "testdata/imported-file.jsonnet",
replaceString: "b: otherfile.bar,",
replaceByString: "b: otherfile.b",
expected: protocol.CompletionList{
Expand All @@ -311,7 +311,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "autocomplete dollar sign",
filename: "testdata/goto-dollar-simple.jsonnet",
filename: "testdata/dollar-simple.jsonnet",
replaceString: "test: $.attribute,",
replaceByString: "test: $.",
expected: protocol.CompletionList{
Expand Down Expand Up @@ -340,7 +340,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "autocomplete dollar sign, end with comma",
filename: "testdata/goto-dollar-simple.jsonnet",
filename: "testdata/dollar-simple.jsonnet",
replaceString: "test: $.attribute,",
replaceByString: "test: $.,",
expected: protocol.CompletionList{
Expand Down Expand Up @@ -369,7 +369,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "autocomplete nested imported file",
filename: "testdata/goto-nested-imported-file.jsonnet",
filename: "testdata/nested-imported-file.jsonnet",
replaceString: "foo: file.foo,",
replaceByString: "foo: file.",
expected: protocol.CompletionList{
Expand Down Expand Up @@ -398,7 +398,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "autocomplete multiple fields within local",
filename: "testdata/goto-indexes.jsonnet",
filename: "testdata/indexes.jsonnet",
replaceString: "attr: obj.foo",
replaceByString: "attr: obj.",
expected: protocol.CompletionList{
Expand Down Expand Up @@ -665,7 +665,7 @@ func TestCompletion(t *testing.T) {
},
{
name: "complete attribute from function",
filename: "testdata/goto-functions.libsonnet",
filename: "testdata/functions.libsonnet",
replaceString: "test: myfunc(arg1, arg2)",
replaceByString: "test: myfunc(arg1, arg2).",
expected: protocol.CompletionList{
Expand Down
Loading
Loading