4 * This file is part of the Behat.
5 * (c) Konstantin Kudryashov <ever.zet@gmail.com>
7 * For the full copyright and license information, please view the LICENSE
8 * file that was distributed with this source code.
11 namespace Behat\Behat\Hook\Scope;
13 use Behat\Gherkin\Node\FeatureNode;
14 use Behat\Testwork\Environment\Environment;
15 use Behat\Testwork\Hook\Scope\AfterTestScope;
16 use Behat\Testwork\Suite\Suite;
17 use Behat\Testwork\Tester\Result\TestResult;
20 * Represents an AfterFeature hook scope.
22 * @author Konstantin Kudryashov <ever.zet@gmail.com>
24 final class AfterFeatureScope implements FeatureScope, AfterTestScope
42 * @param Environment $env
43 * @param FeatureNode $feature
44 * @param TestResult $result
46 public function __construct(Environment $env, FeatureNode $feature, TestResult $result)
48 $this->environment = $env;
49 $this->feature = $feature;
50 $this->result = $result;
54 * Returns hook scope name.
58 public function getName()
68 public function getSuite()
70 return $this->environment->getSuite();
74 * Returns hook environment.
78 public function getEnvironment()
80 return $this->environment;
84 * Returns scope feature.
88 public function getFeature()
90 return $this->feature;
94 * Returns test result.
98 public function getTestResult()
100 return $this->result;