You are here

protected function LingotekSettingsTabUtilitiesFormTest::setUp in Lingotek Translation 3.0.x

Same name in this branch
  1. 3.0.x tests/src/Functional/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Functional\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  2. 3.0.x tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
Same name and namespace in other branches
  1. 8 tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  2. 8.2 tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  3. 4.0.x tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  4. 3.1.x tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  5. 3.2.x tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  6. 3.3.x tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  7. 3.4.x tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  8. 3.5.x tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  9. 3.6.x tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  10. 3.7.x tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()
  11. 3.8.x tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php \Drupal\Tests\lingotek\Unit\Form\LingotekSettingsTabUtilitiesFormTest::setUp()

Overrides UnitTestCase::setUp

File

tests/src/Unit/Form/LingotekSettingsTabUtilitiesFormTest.php, line 67

Class

LingotekSettingsTabUtilitiesFormTest
@coversDefaultClass \Drupal\lingotek\Form\LingotekSettingsTabUtilitiesForm @group lingotek @preserveGlobalState disabled

Namespace

Drupal\Tests\lingotek\Unit\Form

Code

protected function setUp() : void {
  parent::setUp();
  $this->lingotek = $this
    ->createMock(LingotekInterface::class);
  $this->configFactory = $this
    ->createMock(ConfigFactoryInterface::class);
  $this->state = $this
    ->createMock(StateInterface::class);
  $this->routeBuilder = $this
    ->createMock(RouteBuilderInterface::class);
  $this->urlGenerator = $this
    ->createMock(UrlGeneratorInterface::class);
  $this->linkGenerator = $this
    ->createMock(LinkGeneratorInterface::class);
  $messenger = $this
    ->createMock(MessengerInterface::class);
  $this->form = new LingotekSettingsTabUtilitiesForm($this->lingotek, $this->configFactory, $this->state, $this->routeBuilder, $this->urlGenerator, $this->linkGenerator);
  $this->form
    ->setStringTranslation($this
    ->getStringTranslationStub());
  $this->form
    ->setMessenger($messenger);
}