Skip to content
This repository has been archived by the owner on Mar 24, 2020. It is now read-only.

Commit

Permalink
Change package path and mocks path
Browse files Browse the repository at this point in the history
package path changed to
github.com/metal3-io/cluster-api-provider-baremetal

mocks in baremetal/mocks now
  • Loading branch information
maelk committed Feb 12, 2020
1 parent c2d7b55 commit d90d2e1
Show file tree
Hide file tree
Showing 19 changed files with 33 additions and 31 deletions.
6 changes: 4 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -180,14 +180,16 @@ generate-go: $(CONTROLLER_GEN) $(MOCKGEN) $(CONVERSION_GEN) $(KUBEBUILDER) $(KUS
--go-header-file=./hack/boilerplate/boilerplate.generatego.txt

$(MOCKGEN) \
-destination=./baremetal/mock_baremetal/zz_generated.baremetalcluster_manager.go \
-destination=./baremetal/mocks/zz_generated.baremetalcluster_manager.go \
-source=./baremetal/baremetalcluster_manager.go \
-package=baremetal_mocks \
-copyright_file=./hack/boilerplate/boilerplate.generatego.txt \
ClusterManagerInterface

$(MOCKGEN) \
-destination=./baremetal/mock_baremetal/zz_generated.baremetalmachine_manager.go \
-destination=./baremetal/mocks/zz_generated.baremetalmachine_manager.go \
-source=./baremetal/baremetalmachine_manager.go \
-package=baremetal_mocks \
-copyright_file=./hack/boilerplate/boilerplate.generatego.txt \
MachineManagerInterface

Expand Down
2 changes: 1 addition & 1 deletion baremetal/baremetalcluster_manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import (

"k8s.io/apimachinery/pkg/api/equality"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
capbm "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
capbm "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
capi "sigs.k8s.io/cluster-api/api/v1alpha2"
capierrors "sigs.k8s.io/cluster-api/errors"
"sigs.k8s.io/cluster-api/util"
Expand Down
2 changes: 1 addition & 1 deletion baremetal/baremetalcluster_manager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import (
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/klog/klogr"
"k8s.io/utils/pointer"
infrav1 "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
infrav1 "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
clusterv1 "sigs.k8s.io/cluster-api/api/v1alpha2"
capierrors "sigs.k8s.io/cluster-api/errors"
"sigs.k8s.io/controller-runtime/pkg/client"
Expand Down
2 changes: 1 addition & 1 deletion baremetal/baremetalmachine_manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ import (
"github.com/pkg/errors"
apierrors "k8s.io/apimachinery/pkg/api/errors"
clientcorev1 "k8s.io/client-go/kubernetes/typed/core/v1"
capbm "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
capbm "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
capi "sigs.k8s.io/cluster-api/api/v1alpha2"
capierrors "sigs.k8s.io/cluster-api/errors"
"sigs.k8s.io/cluster-api/util"
Expand Down
2 changes: 1 addition & 1 deletion baremetal/baremetalmachine_manager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ import (
clientcorev1 "k8s.io/client-go/kubernetes/typed/core/v1"
"k8s.io/klog/klogr"
"k8s.io/utils/pointer"
capbm "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
capbm "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
capi "sigs.k8s.io/cluster-api/api/v1alpha2"
capierrors "sigs.k8s.io/cluster-api/errors"
"sigs.k8s.io/controller-runtime/pkg/client"
Expand Down
2 changes: 1 addition & 1 deletion baremetal/manager_factory.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package baremetal

import (
"github.com/go-logr/logr"
capbm "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
capbm "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
capi "sigs.k8s.io/cluster-api/api/v1alpha2"
"sigs.k8s.io/controller-runtime/pkg/client"
)
Expand Down
2 changes: 1 addition & 1 deletion baremetal/manager_factory_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (
. "github.com/onsi/gomega"

"k8s.io/klog/klogr"
capbm "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
capbm "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
capi "sigs.k8s.io/cluster-api/api/v1alpha2"
"sigs.k8s.io/controller-runtime/pkg/client"
fakeclient "sigs.k8s.io/controller-runtime/pkg/client/fake"
Expand Down
2 changes: 1 addition & 1 deletion baremetal/mocks/zz_generated.baremetalcluster_manager.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions baremetal/mocks/zz_generated.baremetalmachine_manager.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion baremetal/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
_ "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
"k8s.io/apimachinery/pkg/runtime"
infrav1 "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
infrav1 "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
clusterv1 "sigs.k8s.io/cluster-api/api/v1alpha2"
)

Expand Down
4 changes: 2 additions & 2 deletions controllers/baremetalcluster_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ import (

apierrors "k8s.io/apimachinery/pkg/api/errors"
"k8s.io/utils/pointer"
capbm "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
"sigs.k8s.io/cluster-api-provider-baremetal/baremetal"
capbm "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
"github.com/metal3-io/cluster-api-provider-baremetal/baremetal"
capi "sigs.k8s.io/cluster-api/api/v1alpha2"
capierrors "sigs.k8s.io/cluster-api/errors"
"sigs.k8s.io/cluster-api/util"
Expand Down
4 changes: 2 additions & 2 deletions controllers/baremetalcluster_controller_integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ import (
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/types"
"k8s.io/klog/klogr"
infrav1 "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
"sigs.k8s.io/cluster-api-provider-baremetal/baremetal"
infrav1 "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
"github.com/metal3-io/cluster-api-provider-baremetal/baremetal"

"sigs.k8s.io/controller-runtime/pkg/client/fake"
"sigs.k8s.io/controller-runtime/pkg/reconcile"
Expand Down
2 changes: 1 addition & 1 deletion controllers/baremetalcluster_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (

"github.com/golang/mock/gomock"
"github.com/pkg/errors"
baremetal_mocks "sigs.k8s.io/cluster-api-provider-baremetal/baremetal/mocks"
baremetal_mocks "github.com/metal3-io/cluster-api-provider-baremetal/baremetal/mocks"
)

var _ = Describe("BareMetalCluster controller", func() {
Expand Down
4 changes: 2 additions & 2 deletions controllers/baremetalmachine_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ import (
"k8s.io/apimachinery/pkg/types"
"k8s.io/utils/pointer"

capbm "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
"sigs.k8s.io/cluster-api-provider-baremetal/baremetal"
capbm "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
"github.com/metal3-io/cluster-api-provider-baremetal/baremetal"
capi "sigs.k8s.io/cluster-api/api/v1alpha2"
capierrors "sigs.k8s.io/cluster-api/errors"
"sigs.k8s.io/cluster-api/util"
Expand Down
4 changes: 2 additions & 2 deletions controllers/baremetalmachine_controller_integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ import (
clientfake "k8s.io/client-go/kubernetes/fake"
clientcorev1 "k8s.io/client-go/kubernetes/typed/core/v1"
"k8s.io/klog/klogr"
infrav1 "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
"sigs.k8s.io/cluster-api-provider-baremetal/baremetal"
infrav1 "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
"github.com/metal3-io/cluster-api-provider-baremetal/baremetal"
capi "sigs.k8s.io/cluster-api/api/v1alpha2"
clusterv1 "sigs.k8s.io/cluster-api/api/v1alpha2"
capierrors "sigs.k8s.io/cluster-api/errors"
Expand Down
6 changes: 3 additions & 3 deletions controllers/baremetalmachine_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ import (
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/klog/klogr"
"k8s.io/utils/pointer"
infrav1 "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
"sigs.k8s.io/cluster-api-provider-baremetal/baremetal"
baremetal_mocks "sigs.k8s.io/cluster-api-provider-baremetal/baremetal/mocks"
infrav1 "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
"github.com/metal3-io/cluster-api-provider-baremetal/baremetal"
baremetal_mocks "github.com/metal3-io/cluster-api-provider-baremetal/baremetal/mocks"
"sigs.k8s.io/controller-runtime/pkg/client/fake"
"sigs.k8s.io/controller-runtime/pkg/handler"
)
Expand Down
4 changes: 2 additions & 2 deletions controllers/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ import (
"k8s.io/client-go/kubernetes/scheme"
"k8s.io/client-go/rest"
"k8s.io/klog"
infrastructurev1alpha2 "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
infrav1 "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
infrastructurev1alpha2 "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
infrav1 "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
clusterv1 "sigs.k8s.io/cluster-api/api/v1alpha2"

bmh "github.com/metal3-io/baremetal-operator/pkg/apis/metal3/v1alpha1"
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module sigs.k8s.io/cluster-api-provider-baremetal
module github.com/metal3-io/cluster-api-provider-baremetal

go 1.13

Expand Down
8 changes: 4 additions & 4 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@ import (
"k8s.io/client-go/rest"
"k8s.io/klog"
"k8s.io/klog/klogr"
infrav1 "sigs.k8s.io/cluster-api-provider-baremetal/api/v1alpha2"
"sigs.k8s.io/cluster-api-provider-baremetal/baremetal"
capbmremote "sigs.k8s.io/cluster-api-provider-baremetal/baremetal/remote"
"sigs.k8s.io/cluster-api-provider-baremetal/controllers"
infrav1 "github.com/metal3-io/cluster-api-provider-baremetal/api/v1alpha2"
"github.com/metal3-io/cluster-api-provider-baremetal/baremetal"
capbmremote "github.com/metal3-io/cluster-api-provider-baremetal/baremetal/remote"
"github.com/metal3-io/cluster-api-provider-baremetal/controllers"
clusterv1 "sigs.k8s.io/cluster-api/api/v1alpha2"
ctrl "sigs.k8s.io/controller-runtime"
// +kubebuilder:scaffold:imports
Expand Down

0 comments on commit d90d2e1

Please sign in to comment.