Security update for permissions_by_term
[yaffs-website] / vendor / behat / behat / src / Behat / Behat / EventDispatcher / Event / BeforeScenarioTested.php
1 <?php
2
3 /*
4  * This file is part of the Behat.
5  * (c) Konstantin Kudryashov <ever.zet@gmail.com>
6  *
7  * For the full copyright and license information, please view the LICENSE
8  * file that was distributed with this source code.
9  */
10
11 namespace Behat\Behat\EventDispatcher\Event;
12
13 use Behat\Gherkin\Node\FeatureNode;
14 use Behat\Gherkin\Node\ScenarioLikeInterface as Scenario;
15 use Behat\Gherkin\Node\ScenarioNode;
16 use Behat\Testwork\Environment\Environment;
17 use Behat\Testwork\EventDispatcher\Event\BeforeTested;
18
19 /**
20  * Represents an event before scenario is tested.
21  *
22  * @author Konstantin Kudryashov <ever.zet@gmail.com>
23  */
24 final class BeforeScenarioTested extends ScenarioTested implements BeforeTested
25 {
26     /**
27      * @var FeatureNode
28      */
29     private $feature;
30     /**
31      * @var Scenario
32      */
33     private $scenario;
34
35     /**
36      * Initializes event
37      *
38      * @param Environment $env
39      * @param FeatureNode $feature
40      * @param Scenario    $scenario
41      */
42     public function __construct(Environment $env, FeatureNode $feature, Scenario $scenario)
43     {
44         parent::__construct($env);
45
46         $this->feature = $feature;
47         $this->scenario = $scenario;
48     }
49
50     /**
51      * Returns feature.
52      *
53      * @return FeatureNode
54      */
55     public function getFeature()
56     {
57         return $this->feature;
58     }
59
60     /**
61      * Returns scenario node.
62      *
63      * @return ScenarioNode
64      */
65     public function getScenario()
66     {
67         return $this->scenario;
68     }
69 }