SQL Expressions: (Chore) Update code for latest plugin-sdk data pkg (#100425)

Use new NilAt and SetRefId methods
This commit is contained in:
Kyle Brandt
2025-02-11 10:15:54 -05:00
committed by GitHub
parent 28f21e0a0d
commit f7588376df
3 changed files with 3 additions and 70 deletions

View File

@ -45,11 +45,11 @@ func TestQueryFrames(t *testing.T) {
name: "query all rows from single input frame",
query: `SELECT * FROM inputFrameRefId LIMIT 1;`,
input_frames: []*data.Frame{
setRefID(data.NewFrame(
data.NewFrame(
"",
//nolint:misspell
data.NewField("OSS Projects with Typos", nil, []string{"Garfana", "Pormetheus"}),
), "inputFrameRefId"),
).SetRefID("inputFrameRefId"),
},
expected: data.NewFrame(
"sqlExpressionRefId",
@ -174,8 +174,3 @@ func TestQueryFramesDateTimeSelect(t *testing.T) {
func p[T any](v T) *T {
return &v
}
func setRefID(f *data.Frame, refID string) *data.Frame {
f.RefID = refID
return f
}