You might have come to this situation. A jenkins job runs though there are test case failing and the build appears to be successful. The problem occurs when you have another job on downstream. The downstream will be running even though there was a problem in the upstream job. So to tackle this problem. Initially I tried to write bash script but that was no so effective so I started searching for the plugin. I found this Jenkins plugin which works like a charm.

  • Jenkins plugin Name: TextFinder plugin
  • Jenkins plugin URL:

How Does the TextFinder Jenkins plugin works

The plugin has the feature to search the build logs and we can pass what to look for and based on the result we can decide what to do with the jobs. To make it success or make it unstable. Which is very clear from the image below.

jenkins Text finder plugin for making jobs unstable for error
Reading the jenkins logs to detect failure or success