Skip to content
Snippets Groups Projects

#3361326: MR for the changes.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
28 * The maximum user session.
29 *
21 30 * @var int
22 31 */
23 32 protected $userMaxSessions;
24 33
25 34 /**
35 * The user active session.
36 *
26 37 * @var int
27 38 */
28 39 protected $userActiveSessions;
29 40
30 41 /**
31 * SessionLimitCollisionEvent constructor.
42 * Constructs a new \Drupal\session_limit\Event\SessionLimitCollisionEvent object.
  • 7 7
    8 /**
    9 * Class for session limit collision event.
    10 */
    8 11 class SessionLimitCollisionEvent extends Event {
    9 12
    10 13 /**
    14 * The session ID.
    15 *
    11 16 * @var int
    12 17 */
    13 18 protected $sessionId;
    14 19
    15 20 /**
    16 * @var AccountInterface
    21 * The user account.
  • 27 * The disconnect event status.
    28 *
    21 29 * @var bool
    22 30 */
    23 31 protected $preventDisconnect = FALSE;
    24 32
    25 33 /**
    34 * The message to display.
    35 *
    26 36 * @var string
    27 37 */
    28 38 protected $message;
    29 39
    30 40 /**
    31 * SessionLimitCollisionEvent constructor.
    41 * Constructs a new \Drupal\session_limit\Even\SessionLimitCollisionEvent object.
  • 15 15
    16 16 /**
    17 17 * A store references to different sessions.
    18 *
    19 * @var curlHandles
    20 */
    21 protected $curlHandles = [];
    22 /**
  • 302 309 * getInfo() returns properties that are displayed in the test selection form.
    303 310 */
    304 311 public static function getInfo() {
    305 return array(
    312 return [
    306 313 'name' => 'Session Limit MutiSession Tests',
    307 314 'description' => 'Ensure the multi session tests for SimpleTest work as expected',
    308 315 'group' => 'Session Limit',
    309 );
    316 ];
    310 317 }
    311 318
    312 319 /**
    313 * setUp() performs any pre-requisite tasks that need to happen.
    320 * SetUp() performs any pre-requisite tasks that need to happen.
  • 385 393 * getInfo() returns properties that are displayed in the test selection form.
    386 394 */
    387 395 public static function getInfo() {
    388 return array(
    396 return [
    389 397 'name' => 'Session Limit Logout Tests',
    390 398 'description' => 'Ensure that the session limit module functions as expected when behaviour is set to logout oldest session',
    391 399 'group' => 'Session Limit',
    392 );
    400 ];
    393 401 }
    394 402
    395 403 /**
    396 * setUp() performs any pre-requisite tasks that need to happen.
    404 * SetUp() performs any pre-requisite tasks that need to happen.
  • 427 435 */
    428 436 public function testSessionLimitRoles() {
    429 437 // Create a test user.
    430 $user = $this->drupalCreateUser(array('access content'));
    431 $roles = $this->sessionLimitMakeRoles($user);
    432
    438 $user = $this->drupalCreateUser(['access content']);
    439 // $roles = $this->sessionLimitMakeRoles($user);
  • Thanks please check my comments and check whole code for similar issues.

  • Mohd Sahzad added 1 commit

    added 1 commit

    Compare with previous version

  • 4 4
    5 5 use Symfony\Contracts\EventDispatcher\Event;
    6 6
    7 /**
    8 * Implements session limit bypass event.
  • 4 4
    5 5 use Symfony\Contracts\EventDispatcher\Event;
    6 6
    7 /**
    8 * Implements session limit bypass event.
    9 */
    7 10 class SessionLimitBypassEvent extends Event {
    8 11
    9 12 /**
    13 * The bypass session limit check.
  • 14 19 /**
    15 20 * Tell the session limit module you want to bypass session limit check.
  • 27 32 }
    28 33
    29 34 /**
    35 * Bypass the session limit check.
  • 2 2
    3 3 namespace Drupal\session_limit\Event;
    4 4
    5 use Symfony\Contracts\EventDispatcher\Event;
    6 5 use Drupal\Core\Session\AccountInterface;
    6 use Symfony\Contracts\EventDispatcher\Event;
    7 7
    8 /**
    9 * Class for session limit collision event.
  • 28 * The maximum user session.
    29 *
    21 30 * @var int
    22 31 */
    23 32 protected $userMaxSessions;
    24 33
    25 34 /**
    35 * The user active session.
    36 *
    26 37 * @var int
    27 38 */
    28 39 protected $userActiveSessions;
    29 40
    30 41 /**
    31 * SessionLimitCollisionEvent constructor.
    42 * Constructs a new SessionLimitCollisionEvent object.
  • Preethy Ray added 1 commit

    added 1 commit

    Compare with previous version

  • added 1 commit

    • f1124243 - Added gitlab-ci file to run tests

    Compare with previous version

  • Alastair Moore added 3 commits

    added 3 commits

    • 186a9496 - Removed tests as they’re out of date and the base test class extends a D7...
    • bfa8c978 - Moved methods below class variables/constants for consistency
    • d6246527 - Fixes as recommended by phpstan

    Compare with previous version

  • added 1 commit

    • 575ab63f - Removed the second property description given after the @var line, since...

    Compare with previous version

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading