additional test for jenkins client plugin
@@ -462,8 +462,10 @@ var _ = g.Describe("[Feature:Builds][Slow] openshift pipeline build", func() {
err := oc.Run("create").Args("-f", clientPluginPipelinePath).Execute()
o.Expect(err).NotTo(o.HaveOccurred())
- // start the build
- g.By("starting the pipeline build and waiting for it to complete")
+ // start the build - we run it twice because our sample pipeline exercises different paths of the client
+ // plugin based on whether certain resources already exist or not
+ for i := 0; i < 2; i++ {
+ g.By(fmt.Sprintf("starting the pipeline build and waiting for it to complete, pass: %d", i))
br, err := exutil.StartBuildAndWait(oc, "sample-pipeline-openshift-client-plugin")
debugAnyJenkinsFailure(br, oc.Namespace()+"-sample-pipeline-openshift-client-plugin", oc, true)
if err != nil || !br.BuildSuccess {
@@ -478,6 +480,7 @@ var _ = g.Describe("[Feature:Builds][Slow] openshift pipeline build", func() {
g.By("get build console logs and see if succeeded")
_, err = j.GetJobConsoleLogsAndMatchViaBuildResult(br, "Finished: SUCCESS")
o.Expect(err).NotTo(o.HaveOccurred())
+ }
})
})
