diff -u b/core/modules/taxonomy/src/Plugin/migrate/source/d7/Term.php b/core/modules/taxonomy/src/Plugin/migrate/source/d7/Term.php --- b/core/modules/taxonomy/src/Plugin/migrate/source/d7/Term.php +++ b/core/modules/taxonomy/src/Plugin/migrate/source/d7/Term.php @@ -29,9 +29,7 @@ // Note the explode - this supports the (admittedly unusual) case of // consolidating multiple vocabularies into one. $query = $this->select('taxonomy_term_data', 'td') - ->fields('td', array('tid', 'vid', 'name', 'description', 'weight', 'format')) - // This works, but we cannot test that, because there is no support for - // distinct() in FakeSelect, yet. + ->fields('td') ->distinct(); if (isset($this->configuration['vocabulary'])) { $query->condition('vid', $this->configuration['vocabulary'], 'IN'); diff -u b/core/modules/taxonomy/src/Plugin/migrate/source/d7/Vocabulary.php b/core/modules/taxonomy/src/Plugin/migrate/source/d7/Vocabulary.php --- b/core/modules/taxonomy/src/Plugin/migrate/source/d7/Vocabulary.php +++ b/core/modules/taxonomy/src/Plugin/migrate/source/d7/Vocabulary.php @@ -33,7 +33,7 @@ 'weight', 'machine_name' )); - $query->condition('vid', array(5,6), 'NOT IN'); + $query->condition('vid', array(5, 6), 'NOT IN'); return $query; } diff -u b/core/modules/taxonomy/tests/src/Unit/Migrate/d7/TermTest.php b/core/modules/taxonomy/tests/src/Unit/Migrate/d7/TermTest.php --- b/core/modules/taxonomy/tests/src/Unit/Migrate/d7/TermTest.php +++ b/core/modules/taxonomy/tests/src/Unit/Migrate/d7/TermTest.php @@ -5,7 +5,7 @@ * Contains \Drupal\Tests\taxonomy\Unit\Migrate\d7\TermTestBase. */ -namespace Drupal\Tests\migrate_drupal\Unit\source\d7; +namespace Drupal\Tests\taxonomy\Unit\Migrate\d7; use Drupal\Tests\migrate\Unit\MigrateSqlSourceTestCase; @@ -84,13 +84,13 @@ protected function setUp() { foreach ($this->expectedResults as $k => $row) { foreach ($row['parent'] as $parent) { - $this->databaseContents['term_hierarchy'][] = array( + $this->databaseContents['taxonomy_term_hierarchy'][] = array( 'tid' => $row['tid'], 'parent' => $parent, ); } unset($row['parent']); - $this->databaseContents['term_data'][$k] = $row; + $this->databaseContents['taxonomy_term_data'][$k] = $row; } parent::setUp(); } diff -u b/core/modules/taxonomy/tests/src/Unit/Migrate/d7/VocabularyTest.php b/core/modules/taxonomy/tests/src/Unit/Migrate/d7/VocabularyTest.php --- b/core/modules/taxonomy/tests/src/Unit/Migrate/d7/VocabularyTest.php +++ b/core/modules/taxonomy/tests/src/Unit/Migrate/d7/VocabularyTest.php @@ -62,17 +61,0 @@ - -namespace Drupal\Tests\migrate_drupal\Unit\source\d7; - -use Drupal\Core\Database\Connection; -use Drupal\Core\Extension\ModuleHandlerInterface; -use Drupal\migrate_drupal\Plugin\migrate\source\d7\Vocabulary; - -class TestVocabulary extends Vocabulary { - - public function setDatabase(Connection $database) { - $this->database = $database; - } - public function setModuleHandler(ModuleHandlerInterface $module_handler) { - $this->moduleHandler = $module_handler; - } - -}