@@ -2,7 +2,6 @@ |
||
2 | 2 | |
3 | 3 | use Behat\Behat\Context\Context; |
4 | 4 | use Behat\Behat\Context\SnippetAcceptingContext; |
5 | -use Behat\Behat\Tester\Exception\PendingException; |
|
6 | 5 | use Behat\Gherkin\Node\PyStringNode; |
7 | 6 | |
8 | 7 | class SimpleFeatureContext implements Context, SnippetAcceptingContext { |
@@ -4,7 +4,6 @@ |
||
4 | 4 | |
5 | 5 | use Behat\Behat\Definition\Call\DefinitionCall; |
6 | 6 | use Behat\Behat\Transformation\Transformer\ArgumentTransformer; |
7 | -use rdx\behatvars\BehatVariablesContext; |
|
8 | 7 | use rdx\behatvars\BehatVariablesDatabase; |
9 | 8 | |
10 | 9 | class BehatVariablesArgumentTransformer implements ArgumentTransformer { |
@@ -25,7 +25,7 @@ discard block |
||
25 | 25 | return true; |
26 | 26 | } |
27 | 27 | |
28 | - $slot = self::SLOT_NAME_OPEN . $slot . self::SLOT_NAME_CLOSE; |
|
28 | + $slot = self::SLOT_NAME_OPEN.$slot.self::SLOT_NAME_CLOSE; |
|
29 | 29 | return preg_match(self::SLOT_NAME_REGEX, $slot); |
30 | 30 | } |
31 | 31 | |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | public function transformArgument(DefinitionCall $definitionCall, $argumentIndex, $argumentValue) { |
45 | 45 | $replacements = array(); |
46 | 46 | foreach ($this->matches as $match) { |
47 | - $replacements[ $match[0] ] = BehatVariablesDatabase::get($match[1]); |
|
47 | + $replacements[$match[0]] = BehatVariablesDatabase::get($match[1]); |
|
48 | 48 | } |
49 | 49 | |
50 | 50 | return strtr($argumentValue, $replacements); |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | * @AfterSuite |
32 | 32 | */ |
33 | 33 | public static function cleanTestFolders() { |
34 | - if (is_dir($dir = sys_get_temp_dir() . DIRECTORY_SEPARATOR . 'behat')) { |
|
34 | + if (is_dir($dir = sys_get_temp_dir().DIRECTORY_SEPARATOR.'behat')) { |
|
35 | 35 | self::clearDirectory($dir); |
36 | 36 | } |
37 | 37 | } |
@@ -42,9 +42,9 @@ discard block |
||
42 | 42 | * @BeforeScenario |
43 | 43 | */ |
44 | 44 | public function prepareTestFolders() { |
45 | - $dir = sys_get_temp_dir() . DIRECTORY_SEPARATOR . 'behat' . DIRECTORY_SEPARATOR . md5(microtime() * rand(0, 10000)); |
|
45 | + $dir = sys_get_temp_dir().DIRECTORY_SEPARATOR.'behat'.DIRECTORY_SEPARATOR.md5(microtime() * rand(0, 10000)); |
|
46 | 46 | |
47 | - mkdir($dir . '/features/bootstrap/i18n', 0777, true); |
|
47 | + mkdir($dir.'/features/bootstrap/i18n', 0777, true); |
|
48 | 48 | |
49 | 49 | $phpFinder = new PhpExecutableFinder(); |
50 | 50 | if (false === $php = $phpFinder->find()) { |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | */ |
63 | 63 | public function aFileNamedWith($filename, PyStringNode $content) { |
64 | 64 | $content = strtr((string) $content, array("'''" => '"""')); |
65 | - $this->createFile($this->workingDir . '/' . $filename, $content); |
|
65 | + $this->createFile($this->workingDir.'/'.$filename, $content); |
|
66 | 66 | } |
67 | 67 | |
68 | 68 | /** |
@@ -136,7 +136,7 @@ discard block |
||
136 | 136 | * |
137 | 137 | */ |
138 | 138 | private function getOutput() { |
139 | - $output = $this->process->getErrorOutput() . $this->process->getOutput(); |
|
139 | + $output = $this->process->getErrorOutput().$this->process->getOutput(); |
|
140 | 140 | |
141 | 141 | // Normalize the line endings in the output |
142 | 142 | if ("\n" !== PHP_EOL) { |
@@ -177,7 +177,7 @@ discard block |
||
177 | 177 | array_shift($files); |
178 | 178 | |
179 | 179 | foreach ($files as $file) { |
180 | - $file = $path . DIRECTORY_SEPARATOR . $file; |
|
180 | + $file = $path.DIRECTORY_SEPARATOR.$file; |
|
181 | 181 | if (is_dir($file)) { |
182 | 182 | self::clearDirectory($file); |
183 | 183 | } else { |
@@ -61,7 +61,7 @@ |
||
61 | 61 | */ |
62 | 62 | static public function __callStatic($method, $args) { |
63 | 63 | $instance = static::instance(); |
64 | - return call_user_func_array(array($instance, '_' . $method), $args); |
|
64 | + return call_user_func_array(array($instance, '_'.$method), $args); |
|
65 | 65 | } |
66 | 66 | |
67 | 67 | } |