Upgraded drupal core with security updates
[yaffs-website] / web / core / modules / language / tests / src / Kernel / Plugin / migrate / source / d6 / LanguageContentSettingsTest.php
1 <?php
2
3 namespace Drupal\Tests\language\Kernel\Plugin\migrate\source\d6;
4
5 use Drupal\Tests\migrate\Kernel\MigrateSqlSourceTestBase;
6
7 /**
8  * Tests menu source plugin.
9  *
10  * @covers \Drupal\language\Plugin\migrate\source\d6\LanguageContentSettings
11  *
12  * @group language
13  */
14 class LanguageContentSettingsTest extends MigrateSqlSourceTestBase {
15
16   /**
17    * {@inheritdoc}
18    */
19   public static $modules = ['language', 'migrate_drupal'];
20
21   /**
22    * {@inheritdoc}
23    */
24   public function providerSource() {
25     $tests = [];
26
27     // The source data.
28     $tests[0]['source_data']['node_type'] = [
29       [
30         'type' => 'article',
31         'name' => 'Article',
32         'module' => 'node',
33         'description' => 'An <em>article</em>, content type.',
34         'help' => '',
35         'has_title' => 1,
36         'title_label' => 'Title',
37         'has_body' => 1,
38         'body_label' => 'Body',
39         'min_word_count' => 0,
40         'custom' => 1,
41         'modified' => 1,
42         'locked' => 0,
43         'orig_type' => 'story',
44       ],
45       [
46         'type' => 'company',
47         'name' => 'Company',
48         'module' => 'node',
49         'description' => 'Company node type',
50         'help' => '',
51         'has_title' => 1,
52         'title_label' => 'Name',
53         'has_body' => 1,
54         'body_label' => 'Description',
55         'min_word_count' => 0,
56         'custom' => 0,
57         'modified' => 1,
58         'locked' => 0,
59         'orig_type' => 'company',
60       ],
61     ];
62
63     foreach ($tests[0]['source_data']['node_type'] as $node_type) {
64       $tests[0]['expected_data'][] = [
65         'type' => $node_type['type'],
66         'language_content_type' => NULL,
67         'i18n_lock_node' => 0,
68       ];
69     }
70
71     return $tests;
72   }
73
74 }