Completed
Pull Request — master (#16)
by Sergii
07:37
created
src/Context/RawPageContext.php 1 patch
Unused Use Statements   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -11,8 +11,8 @@
 block discarded – undo
11 11
 // Helpers.
12 12
 use Behat\Mink\Element\NodeElement;
13 13
 // Utils.
14
-use Drupal\TqExtension\Utils\XPath;
15 14
 use Drupal\TqExtension\Cores\DrupalKernelPlaceholder;
15
+use Drupal\TqExtension\Utils\XPath;
16 16
 
17 17
 class RawPageContext extends RawDrupalContext
18 18
 {
Please login to merge, or discard this patch.
src/Context/TqContext.php 1 patch
Unused Use Statements   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -7,9 +7,9 @@
 block discarded – undo
7 7
 // Scope definitions.
8 8
 use Behat\Behat\Hook\Scope;
9 9
 // Utils.
10
+use Drupal\TqExtension\Cores\DrupalKernelPlaceholder;
10 11
 use Drupal\TqExtension\Utils\Database\Database;
11 12
 use Drupal\TqExtension\Utils\LogicalAssertion;
12
-use Drupal\TqExtension\Cores\DrupalKernelPlaceholder;
13 13
 
14 14
 class TqContext extends RawTqContext
15 15
 {
Please login to merge, or discard this patch.
src/Cores/Drupal8Placeholder.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -165,7 +165,7 @@
 block discarded – undo
165 165
         static $original = 'php_mail';
166 166
 
167 167
         $systemMail = \Drupal::configFactory()
168
-          ->getEditable('system.mail');
168
+            ->getEditable('system.mail');
169 169
 
170 170
         if ($useTesting) {
171 171
             // Store original mail system to restore it after scenario.
Please login to merge, or discard this patch.
Unused Use Statements   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -5,14 +5,14 @@
 block discarded – undo
5 5
 namespace Drupal\TqExtension\Cores;
6 6
 
7 7
 use Behat\Behat\Hook\Scope\BeforeFeatureScope;
8
-use Drupal\Core\Field\FieldDefinitionInterface;
9
-use Drupal\Core\Entity\FieldableEntityInterface;
10
-use Drupal\Core\Session\AccountInterface;
8
+use Drupal\Component\Render\FormattableMarkup;
9
+use Drupal\Component\Serialization\Json;
11 10
 use Drupal\Core\Database\Database;
12 11
 use Drupal\Core\Database\Query\Select;
12
+use Drupal\Core\Entity\FieldableEntityInterface;
13
+use Drupal\Core\Field\FieldDefinitionInterface;
14
+use Drupal\Core\Session\AccountInterface;
13 15
 use Drupal\Core\StringTranslation\TranslatableMarkup;
14
-use Drupal\Component\Render\FormattableMarkup;
15
-use Drupal\Component\Serialization\Json;
16 16
 use Drupal\TqExtension\Utils\Database\FetchField;
17 17
 
18 18
 final class Drupal8Placeholder extends DrupalKernelPlaceholder
Please login to merge, or discard this patch.
src/Context/RawTqContext.php 1 patch
Unused Use Statements   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -11,22 +11,22 @@
 block discarded – undo
11 11
 use Behat\Behat\Context\Exception\ContextNotFoundException;
12 12
 use Behat\DebugExtension\Debugger;
13 13
 // Helpers.
14
-use WebDriver\Session;
15
-use Drupal\Driver\DrushDriver;
16
-use Drupal\Driver\DriverInterface as DrupalDriverInterface;
17
-use Drupal\Component\Utility\Random;
18
-use Behat\Mink\Element\NodeElement;
14
+use Behat\Behat\Context\Environment\InitializedContextEnvironment;
15
+use Behat\Behat\Hook\Scope\StepScope;
16
+use Behat\Mink\Driver\DriverInterface as SessionDriverInterface;
19 17
 use Behat\Mink\Driver\GoutteDriver;
20 18
 use Behat\Mink\Driver\Selenium2Driver;
21
-use Behat\Mink\Driver\DriverInterface as SessionDriverInterface;
22
-use Behat\Behat\Hook\Scope\StepScope;
23
-use Behat\Behat\Context\Environment\InitializedContextEnvironment;
19
+use Behat\Mink\Element\NodeElement;
24 20
 use Behat\Testwork\Environment\Environment;
21
+use Drupal\Component\Utility\Random;
22
+use Drupal\Driver\DriverInterface as DrupalDriverInterface;
23
+use Drupal\Driver\DrushDriver;
24
+use WebDriver\Session;
25 25
 // Utils.
26
-use Drupal\TqExtension\Utils\Url;
27
-use Drupal\TqExtension\Utils\Tags;
28
-use Drupal\TqExtension\Utils\JavaScript;
29 26
 use Drupal\TqExtension\Cores\DrupalKernelPlaceholder;
27
+use Drupal\TqExtension\Utils\JavaScript;
28
+use Drupal\TqExtension\Utils\Tags;
29
+use Drupal\TqExtension\Utils\Url;
30 30
 
31 31
 /**
32 32
  * @see RawTqContext::__call()
Please login to merge, or discard this patch.
src/Context/User/RawUserContext.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -30,8 +30,8 @@  discard block
 block discarded – undo
30 30
     public function getCurrentId()
31 31
     {
32 32
         $currentUser = $this
33
-          ->getUserManager()
34
-          ->getCurrentUser();
33
+            ->getUserManager()
34
+            ->getCurrentUser();
35 35
 
36 36
         return empty($currentUser->uid) ? 0 : $currentUser->uid;
37 37
     }
@@ -117,8 +117,8 @@  discard block
 block discarded – undo
117 117
 
118 118
         $account = user_load_by_name($props['username']);
119 119
         $this
120
-          ->getUserManager()
121
-          ->setCurrentUser($account);
120
+            ->getUserManager()
121
+            ->setCurrentUser($account);
122 122
 
123 123
         DrupalKernelPlaceholder::setCurrentUser($account);
124 124
     }
Please login to merge, or discard this patch.
src/Context/Form/FormContext.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -114,8 +114,8 @@
 block discarded – undo
114 114
     public function fillInWithValueOfFieldOfCurrentUser($field, $userField)
115 115
     {
116 116
         $currentUser = $this
117
-          ->getUserManager()
118
-          ->getCurrentUser();
117
+            ->getUserManager()
118
+            ->getCurrentUser();
119 119
 
120 120
         if (!empty($currentUser) && empty($currentUser->uid)) {
121 121
             throw new \Exception('Anonymous user have no fields');
Please login to merge, or discard this patch.