Skip to content

Commit

Permalink
Add visibility control to dynamic log links
Browse files Browse the repository at this point in the history
Signed-off-by: Kevin Su <[email protected]>
  • Loading branch information
pingsutw committed Nov 12, 2024
1 parent eb0c40d commit c341ff1
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions flyteplugins/go/tasks/pluginmachinery/tasklog/template_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -478,6 +478,37 @@ func TestTemplateLogPlugin(t *testing.T) {
},
},
},
{
"flyteinteractive",
TemplateLogPlugin{
Name: "vscode",
DynamicTemplateURIs: []TemplateURI{"vscode://flyteinteractive:{{ .taskConfig.port }}/{{ .podName }}"},
MessageFormat: core.TaskLog_JSON,
HideOnceFinished: true,
ShowWhilePending: true,
},
args{
input: Input{
PodName: "my-pod-name",
TaskTemplate: &core.TaskTemplate{
Config: map[string]string{
"link_type": "vscode",
"port": "1234",
},
},
},
},
Output{
TaskLogs: []*core.TaskLog{
{
Uri: "vscode://flyteinteractive:1234/my-pod-name",
MessageFormat: core.TaskLog_JSON,
ShowWhilePending: true,
HideOnceFinished: true,
},
},
},
},
{
"flyteinteractive - no link_type in task template",
TemplateLogPlugin{
Expand Down

0 comments on commit c341ff1

Please sign in to comment.