pho\Runner\Runner::beforeEach PHP Method

beforeEach() public method

Constructs a new Hook, defining a closure to be ran prior to each of the parent suite's nested suites and specs.
public beforeEach ( Closure $closure )
$closure Closure The closure to be ran before each spec
    public function beforeEach(\Closure $closure)
    {
        $beforeEach = new Hook($closure, $this->current);
        $this->current->setHook('beforeEach', $beforeEach);
    }