mirror of
https://github.com/jenkinsci/kubernetes-operator.git
synced 2026-10-18 05:54:47 +02:00
Move to operator-sdk v.0.17.0
This commit is contained in:
@@ -26,7 +26,7 @@ func TestLintHelmChart(t *testing.T) {
|
||||
func TestDeployHelmChart(t *testing.T) {
|
||||
// Given
|
||||
t.Parallel()
|
||||
ctx := framework.NewTestCtx(t)
|
||||
ctx := framework.NewContext(t)
|
||||
defer ctx.Cleanup()
|
||||
|
||||
namespace, err := ctx.GetNamespace()
|
||||
|
||||
@@ -28,8 +28,8 @@ func TestMain(m *testing.M) {
|
||||
framework.MainEntry(m)
|
||||
}
|
||||
|
||||
func setupTest(t *testing.T) (string, *framework.TestCtx) {
|
||||
ctx := framework.NewTestCtx(t)
|
||||
func setupTest(t *testing.T) (string, *framework.Context) {
|
||||
ctx := framework.NewContext(t)
|
||||
err := ctx.InitializeClusterResources(nil)
|
||||
if err != nil {
|
||||
t.Fatalf("could not initialize cluster resources: %v", err)
|
||||
@@ -53,7 +53,7 @@ func setupTest(t *testing.T) (string, *framework.TestCtx) {
|
||||
t.Fatalf("could not add scheme to framework scheme: %v", err)
|
||||
}
|
||||
|
||||
namespace, err := ctx.GetNamespace()
|
||||
namespace, err := ctx.GetOperatorNamespace()
|
||||
if err != nil {
|
||||
t.Fatalf("could not get namespace: %v", err)
|
||||
}
|
||||
|
||||
@@ -125,8 +125,8 @@ func printKubernetesPods(t *testing.T, namespace string) {
|
||||
}
|
||||
}
|
||||
|
||||
func showLogsIfTestHasFailed(t *testing.T, ctx *framework.TestCtx) {
|
||||
namespace, err := ctx.GetNamespace()
|
||||
func showLogsIfTestHasFailed(t *testing.T, ctx *framework.Context) {
|
||||
namespace, err := ctx.GetOperatorNamespace()
|
||||
if err != nil {
|
||||
t.Fatalf("Failed to get '%s' namespace", err)
|
||||
}
|
||||
@@ -140,8 +140,8 @@ func showLogsIfTestHasFailed(t *testing.T, ctx *framework.TestCtx) {
|
||||
}
|
||||
}
|
||||
|
||||
func showLogsAndCleanup(t *testing.T, ctx *framework.TestCtx) {
|
||||
namespace, err := ctx.GetNamespace()
|
||||
func showLogsAndCleanup(t *testing.T, ctx *framework.Context) {
|
||||
namespace, err := ctx.GetOperatorNamespace()
|
||||
if err != nil {
|
||||
t.Fatalf("Failed to get '%s' namespace", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user