MDL-64570 user: coding style
authorDamyon Wiese <damyon@moodle.com>
Tue, 29 Jan 2019 03:36:44 +0000 (11:36 +0800)
committerDamyon Wiese <damyon@moodle.com>
Tue, 19 Feb 2019 01:44:20 +0000 (09:44 +0800)
Fix cibot warnings on line length.

blocks/login/block_login.php
user/tests/behat/behat_user.php

index 24e6595..8247355 100644 (file)
@@ -66,12 +66,16 @@ class block_login extends block_base {
 
             $this->content->text .= "\n".'<form class="loginform" id="login" method="post" action="'.get_login_url().'">';
 
-            $this->content->text .= '<div class="form-group"><label for="login_username">'.$strusername.'</label>';
-            $this->content->text .= '<input type="text" name="username" id="login_username" class="form-control" value="'.s($username).'" autocomplete="username"/></div>';
+            $this->content->text .= '<div class="form-group">';
+            $this->content->text .= '<label for="login_username">'.$strusername.'</label>';
+            $this->content->text .= '<input type="text" name="username" id="login_username" ';
+            $this->content->text .= ' class="form-control" value="'.s($username).'" autocomplete="username"/></div>';
 
             $this->content->text .= '<div class="form-group"><label for="login_password">'.get_string('password').'</label>';
 
-            $this->content->text .= '<input type="password" name="password" id="login_password" class="form-control" value="" autocomplete="current-password"/></div>';
+            $this->content->text .= '<input type="password" name="password" id="login_password" ';
+            $this->content->text .= ' class="form-control" value="" autocomplete="current-password"/>';
+            $this->content->text .= '</div>';
 
             if (isset($CFG->rememberusername) and $CFG->rememberusername == 2) {
                 $checked = $username ? 'checked="checked"' : '';
index 2a6f3da..2e39f12 100644 (file)
@@ -66,7 +66,8 @@ class behat_user extends behat_base {
 
         $value = $fld->get_attribute('autocomplete');
         if ($value != $purpose) {
-            throw new ExpectationException('The "' . $field . '" field does not have purposea "' . $purpose . '"', $this->getSession());
+            $reason = 'The "' . $field . '" field does not have purpose "' . $purpose . '"';
+            throw new ExpectationException($reason, $this->getSession());
         }
     }