0

I try to write a custom step that's generate step

my code looks like :

/**
 * @Then /^Check_raoul$/
 */
public function checkRaoul()
{
    // grab the content ...

    // get players ...
    $to_return = array();
    foreach ($players as $player) {
        $player = $player->textContent;
        if (preg_match('/^.*video=([^&]*)&.*$/', $player, $matches))
        {
            array_push($to_return, new Step\Then('I check the video of id "'.$matches[1].'"'));
        }
    }
    return $to_return;
}

/**
 * @Then /^I check the video of id "([^"]*)"$/
 */
public function iCheckTheVideoOfId($id)
{
// ...
}

works fine but when integrating to jenkins or un cli, if many executions of iCheckTheVideoOfId fail, I see just one error. I wish generate a number of steps equal to the number of iCheckTheVideoOfId calls

what I a doing wrong ?

1 Answers1

0

We abandoned using Jenkins to do BDD checks due to the differences in how test feedback is presented and what Jenkins is capable of. We found that just running our suites locally and then a full check before pushing code to the repo produced better results and helped everyone get better at using the framework.

To answer your question directly I would suggest configuring your jenkins job to not fail when a test fails. This can be accomplished by not outputting results at all. You can modify your command line options to not output failures at all and just log results to an output file. You could then run a script at the end to check for failures.

branchgabriel
  • 4,241
  • 4
  • 34
  • 48