From b27aef18084946f40670c498c92bd5ab3fb4bcbd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tomasz=20S=C4=99k?= Date: Mon, 6 Jan 2020 20:41:36 +0100 Subject: [PATCH] #200 Fix e2e --- deploy/role.yaml | 1 + test/e2e/jenkins.go | 14 +++++++------- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/deploy/role.yaml b/deploy/role.yaml index d6e7aaa1..17a37f79 100644 --- a/deploy/role.yaml +++ b/deploy/role.yaml @@ -39,6 +39,7 @@ rules: verbs: - create - update + - list - apiGroups: - "" resources: diff --git a/test/e2e/jenkins.go b/test/e2e/jenkins.go index 594699c3..cc197e56 100644 --- a/test/e2e/jenkins.go +++ b/test/e2e/jenkins.go @@ -145,13 +145,13 @@ func createJenkinsCR(t *testing.T, name, namespace string, seedJob *[]v1alpha2.S Type: corev1.ServiceTypeNodePort, Port: constants.DefaultHTTPPortInt32, }, - Roles: []rbacv1.RoleRef{ - { - APIGroup: "rbac.authorization.k8s.io", - Kind: "ClusterRole", - Name: "view", - }, - }, + }, + } + jenkins.Spec.Roles = []rbacv1.RoleRef{ + { + APIGroup: "rbac.authorization.k8s.io", + Kind: "Role", + Name: resources.GetResourceName(jenkins), }, }