public function LingotekFake::getAccountInfo in Lingotek Translation 4.0.x
Same name and namespace in other branches
- 8 tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
- 8.2 tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
- 3.0.x tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
- 3.1.x tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
- 3.2.x tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
- 3.3.x tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
- 3.4.x tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
- 3.5.x tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
- 3.6.x tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
- 3.7.x tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
- 3.8.x tests/modules/lingotek_test/src/LingotekFake.php \Drupal\lingotek_test\LingotekFake::getAccountInfo()
Get the account information.
Return value
array|bool Array with account info. FALSE in case of error. The keys are user_id, username, login_id, email, and name.
Overrides LingotekInterface::getAccountInfo
File
- tests/modules/ lingotek_test/ src/ LingotekFake.php, line 51 
Class
Namespace
Drupal\lingotek_testCode
public function getAccountInfo() {
  \Drupal::state()
    ->set('lingotek_fake.setup_completed', TRUE);
  // We need to store the resources. Let's force that.
  return [
    'id' => 'test',
    'type' => 'token',
    'client_id' => 'test_default_client_id',
    'user_id' => 'testUser',
    'login_id' => 'testUser@example.com',
    'expires_at' => -1,
  ];
}