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

Commit

Permalink
fix(TypeMeta) : Remove TypeMeta declaration from the implementation o…
Browse files Browse the repository at this point in the history
…f the objects
  • Loading branch information
camilamacedo86 committed May 21, 2019
1 parent 26a0c41 commit c05e3bd
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 14 deletions.
3 changes: 3 additions & 0 deletions memcached-operator/.gitignore
@@ -1,3 +1,6 @@
#IDEA
.idea/*

# Temporary Build Files
build/_output
build/_test
Expand Down
Expand Up @@ -167,10 +167,6 @@ func (r *ReconcileMemcached) deploymentForMemcached(m *cachev1alpha1.Memcached)
replicas := m.Spec.Size

dep := &appsv1.Deployment{
TypeMeta: metav1.TypeMeta{
APIVersion: "apps/v1",
Kind: "Deployment",
},
ObjectMeta: metav1.ObjectMeta{
Name: m.Name,
Namespace: m.Namespace,
Expand Down
11 changes: 1 addition & 10 deletions memcached-operator/test/e2e/memcached_test.go
Expand Up @@ -37,12 +37,7 @@ var (
)

func TestMemcached(t *testing.T) {
memcachedList := &operator.MemcachedList{
TypeMeta: metav1.TypeMeta{
Kind: "Memcached",
APIVersion: "cache.example.com/v1alpha1",
},
}
memcachedList := &operator.MemcachedList{}
err := framework.AddToFrameworkScheme(apis.AddToScheme, memcachedList)
if err != nil {
t.Fatalf("failed to add custom resource scheme to framework: %v", err)
Expand All @@ -61,10 +56,6 @@ func memcachedScaleTest(t *testing.T, f *framework.Framework, ctx *framework.Tes
}
// create memcached custom resource
exampleMemcached := &operator.Memcached{
TypeMeta: metav1.TypeMeta{
Kind: "Memcached",
APIVersion: "cache.example.com/v1alpha1",
},
ObjectMeta: metav1.ObjectMeta{
Name: "example-memcached",
Namespace: namespace,
Expand Down

0 comments on commit c05e3bd

Please sign in to comment.