Skip to content
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
3 changes: 2 additions & 1 deletion pkg/workloadmanager/auth_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import (
"fmt"
"net/http"
"net/http/httptest"
"strings"
"testing"
"time"

Expand Down Expand Up @@ -223,7 +224,7 @@ func TestAuthMiddleware_ServiceAccountParsing(t *testing.T) {

for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
token := "token-" + tt.name
token := "token-" + strings.ReplaceAll(tt.name, " ", "-")
server.tokenCache.Set(token, true, tt.username)

w := httptest.NewRecorder()
Expand Down
4 changes: 3 additions & 1 deletion pkg/workloadmanager/sandbox_helper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,9 @@ func TestBuildSandboxInfo_TableDriven(t *testing.T) {
CreationTimestamp: metav1.NewTime(now),
},
Spec: sandboxv1alpha1.SandboxSpec{
ShutdownTime: &metav1.Time{Time: shutdownTime},
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Both are right,

	// Lifecycle defines when and how the sandbox should be shut down.
	// +optional
	Lifecycle `json:",inline"`

Lifecycle: sandboxv1alpha1.Lifecycle{
ShutdownTime: &metav1.Time{Time: shutdownTime},
},
},
Status: sandboxv1alpha1.SandboxStatus{
Conditions: []metav1.Condition{
Expand Down
Loading