You are here

public static function EntityUpdateTestHelper::fieldSetType in Entity Update 2.0.x

Same name and namespace in other branches
  1. 8 modules/entity_update_tests/src/EntityUpdateTestHelper.php \Drupal\entity_update_tests\EntityUpdateTestHelper::fieldSetType()

Set Field type.

6 calls to EntityUpdateTestHelper::fieldSetType()
EntityUpdateFunctionsTest::setUp in tests/src/Functional/EntityUpdateFunctionsTest.php
EntityUpdateFunctionsTest::testEntityUpdateAll in tests/src/Functional/EntityUpdateFunctionsTest.php
Entity update function : all.
EntityUpdateFunctionsTest::testEntityUpdateBasic in tests/src/Functional/EntityUpdateFunctionsTest.php
Entity update function : basic.
EntityUpdateProgUpTest::setUp in tests/src/Functional/EntityUpdateProgUpTest.php
EntityUpdateUIFunctionsTest::testEntityUpdateBasicWebExec in tests/src/Functional/EntityUpdateUIFunctionsTest.php
Run basic tests.

... See full list

File

tests/modules/entity_update_tests/src/EntityUpdateTestHelper.php, line 57

Class

EntityUpdateTestHelper
EntityUpdateTest Helper functions.

Namespace

Drupal\entity_update_tests

Code

public static function fieldSetType($name, $type = 'string') {
  $config = self::getConfig(TRUE);
  $config
    ->set("fields." . $name, $type);
  $config
    ->save();
}