You are here

public function EntityBrowserUpdateHookTest::testSubmitTextUpdate in Entity Browser 8

Same name and namespace in other branches
  1. 8.2 tests/src/Functional/EntityBrowserUpdateHookTest.php \Drupal\Tests\entity_browser\Functional\EntityBrowserUpdateHookTest::testSubmitTextUpdate()

Tests entity_browser_update_8001().

File

tests/src/Functional/EntityBrowserUpdateHookTest.php, line 55

Class

EntityBrowserUpdateHookTest
Tests the update hooks in entity_browser module.

Namespace

Drupal\Tests\entity_browser\Functional

Code

public function testSubmitTextUpdate() {
  $this
    ->runUpdates();
  $browser = $this->container
    ->get('config.factory')
    ->get('entity_browser.browser.test_update');
  $this
    ->assertNull($browser
    ->get('submit_text'), 'Old submit text is gone');
  $this
    ->assertEquals('All animals are created equal', $browser
    ->get('widgets.a4ad947c-9669-497c-9988-24351955a02f.settings.submit_text'), 'New submit text appears on the widget.');
}