Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / modules / datetime / tests / src / Unit / Plugin / migrate / field / DateFieldTest.php
index 6b7f13727e1638d5e8f674a933065010861f0b34..500eac2307bb4ccfcc6400e6fa8486a83a8f2c3b 100644 (file)
@@ -11,25 +11,15 @@ use Drupal\Tests\UnitTestCase;
  */
 class DateFieldTest extends UnitTestCase {
 
-  /**
-   * @var \Drupal\migrate_drupal\Plugin\MigrateFieldInterface
-   */
-  protected $plugin;
-
-  /**
-   * @var \Drupal\migrate\Plugin\MigrationInterface
-   */
-  protected $migration;
-
   /**
    * Tests an Exception is thrown when the field type is not a known date type.
    */
-  public function testUnknownDateType() {
-    $this->migration = $this->prophesize('Drupal\migrate\Plugin\MigrationInterface')->reveal();
-    $this->plugin = new DateField([], '', []);
+  public function testUnknownDateType($method = 'defineValueProcessPipeline') {
+    $migration = $this->prophesize('Drupal\migrate\Plugin\MigrationInterface')->reveal();
+    $plugin = new DateField([], '', []);
 
     $this->setExpectedException(MigrateException::class, "Field field_date of type 'timestamp' is an unknown date field type.");
-    $this->plugin->processFieldValues($this->migration, 'field_date', ['type' => 'timestamp']);
+    $plugin->$method($migration, 'field_date', ['type' => 'timestamp']);
   }
 
 }