Skip to content

Commit

Permalink
ci: goimports and gofmt
Browse files Browse the repository at this point in the history
Signed-off-by: LY-today <[email protected]>
  • Loading branch information
LY-today committed Dec 20, 2024
1 parent 06a124a commit 1d3616a
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,16 @@ package noderesourcesfitplus
import (
"context"
"fmt"
"github.com/koordinator-sh/koordinator/pkg/scheduler/apis/config"

v1 "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/kubernetes/pkg/api/v1/resource"
k8sConfig "k8s.io/kubernetes/pkg/scheduler/apis/config"
"k8s.io/kubernetes/pkg/scheduler/framework"
plfeature "k8s.io/kubernetes/pkg/scheduler/framework/plugins/feature"
"k8s.io/kubernetes/pkg/scheduler/framework/plugins/noderesources"

"github.com/koordinator-sh/koordinator/pkg/scheduler/apis/config"
)

const (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,9 @@ func TestPlugin_Score(t *testing.T) {

var v1beta2args v1beta3.NodeResourcesFitPlusArgs
v1beta2args.Resources = map[v1.ResourceName]v1beta3.ResourcesType{
"nvidia.com/gpu": v1beta3.ResourcesType{Type: k8sConfig.MostAllocated, Weight: 2},
"cpu": v1beta3.ResourcesType{Type: k8sConfig.LeastAllocated, Weight: 1},
"memory": v1beta3.ResourcesType{Type: k8sConfig.LeastAllocated, Weight: 1},
"nvidia.com/gpu": {Type: k8sConfig.MostAllocated, Weight: 2},
"cpu": {Type: k8sConfig.LeastAllocated, Weight: 1},
"memory": {Type: k8sConfig.LeastAllocated, Weight: 1},
}

var nodeResourcesFitPlusArgs config.NodeResourcesFitPlusArgs
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,13 @@ package scarceresourceavoidance
import (
"context"
"fmt"
"github.com/koordinator-sh/koordinator/pkg/scheduler/apis/config"

v1 "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/kubernetes/pkg/api/v1/resource"
"k8s.io/kubernetes/pkg/scheduler/framework"

"github.com/koordinator-sh/koordinator/pkg/scheduler/apis/config"
)

const (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,8 @@ package scarceresourceavoidance

import (
"context"
koordinatorclientset "github.com/koordinator-sh/koordinator/pkg/client/clientset/versioned"
koordfake "github.com/koordinator-sh/koordinator/pkg/client/clientset/versioned/fake"
koordinatorinformers "github.com/koordinator-sh/koordinator/pkg/client/informers/externalversions"
"github.com/koordinator-sh/koordinator/pkg/scheduler/apis/config"
"github.com/koordinator-sh/koordinator/pkg/scheduler/apis/config/v1beta3"
"github.com/koordinator-sh/koordinator/pkg/scheduler/frameworkext"
"testing"

"github.com/stretchr/testify/assert"
corev1 "k8s.io/api/core/v1"
v1 "k8s.io/api/core/v1"
Expand All @@ -21,7 +17,13 @@ import (
"k8s.io/kubernetes/pkg/scheduler/framework/plugins/queuesort"
frameworkruntime "k8s.io/kubernetes/pkg/scheduler/framework/runtime"
schedulertesting "k8s.io/kubernetes/pkg/scheduler/testing"
"testing"

koordinatorclientset "github.com/koordinator-sh/koordinator/pkg/client/clientset/versioned"
koordfake "github.com/koordinator-sh/koordinator/pkg/client/clientset/versioned/fake"
koordinatorinformers "github.com/koordinator-sh/koordinator/pkg/client/informers/externalversions"
"github.com/koordinator-sh/koordinator/pkg/scheduler/apis/config"
"github.com/koordinator-sh/koordinator/pkg/scheduler/apis/config/v1beta3"
"github.com/koordinator-sh/koordinator/pkg/scheduler/frameworkext"
)

var _ framework.SharedLister = &testSharedLister{}
Expand Down

0 comments on commit 1d3616a

Please sign in to comment.