diff --git a/core/modules/image/src/Tests/ImageFieldDisplayTest.php b/core/modules/image/src/Tests/ImageFieldDisplayTest.php
index f6ca758..8223b33 100644
--- a/core/modules/image/src/Tests/ImageFieldDisplayTest.php
+++ b/core/modules/image/src/Tests/ImageFieldDisplayTest.php
@@ -178,12 +178,11 @@ function testImageFieldSettings() {
       'max_resolution' => '100x100',
       'min_resolution' => '10x10',
       'title_field' => 1,
-      'description' => '[site:name]_description',
     );
     $widget_settings = array(
       'preview_image_style' => 'medium',
     );
-    $field = $this->createImageField($field_name, 'article', array(), $field_settings, $widget_settings);
+    $field = $this->createImageField($field_name, 'article', array(), $field_settings, $widget_settings, '[site:name]_description');
 
     $this->drupalGet('node/add/article');
     $this->assertText(t('50 KB limit.'), 'Image widget max file size is displayed on article form.');
diff --git a/core/modules/image/src/Tests/ImageFieldTestBase.php b/core/modules/image/src/Tests/ImageFieldTestBase.php
index 567389f..0bd99b9 100644
--- a/core/modules/image/src/Tests/ImageFieldTestBase.php
+++ b/core/modules/image/src/Tests/ImageFieldTestBase.php
@@ -61,18 +61,20 @@ protected function setUp() {
   /**
    * Create a new image field.
    *
-   * @param $name
+   * @param string $name
    *   The name of the new field (all lowercase), exclude the "field_" prefix.
-   * @param $type_name
+   * @param string $type_name
    *   The node type that this field will be added to.
-   * @param $storage_settings
+   * @param array $storage_settings
    *   A list of field storage settings that will be added to the defaults.
-   * @param $field_settings
+   * @param array $field_settings
    *   A list of instance settings that will be added to the instance defaults.
-   * @param $widget_settings
+   * @param array $widget_settings
    *   A list of widget settings that will be added to the widget defaults.
+   * @param string $description
+   *   Optional field description.
    */
-  function createImageField($name, $type_name, $storage_settings = array(), $field_settings = array(), $widget_settings = array()) {
+  function createImageField($name, $type_name, $storage_settings = array(), $field_settings = array(), $widget_settings = array(), $description = '') {
     entity_create('field_storage_config', array(
       'field_name' => $name,
       'entity_type' => 'node',
@@ -81,8 +83,6 @@ function createImageField($name, $type_name, $storage_settings = array(), $field
       'cardinality' => !empty($storage_settings['cardinality']) ? $storage_settings['cardinality'] : 1,
     ))->save();
 
-    $description = !empty($field_settings['description']) ? $field_settings['description'] : '';
-    unset($field_settings['description']);
     $field_config = entity_create('field_config', array(
       'field_name' => $name,
       'label' => $name,
