function EntityDecoupledTranslationRevisionsTest::dataTestDecoupledPendingRevisions

Same name in other branches
  1. 9 core/tests/Drupal/KernelTests/Core/Entity/EntityDecoupledTranslationRevisionsTest.php \Drupal\KernelTests\Core\Entity\EntityDecoupledTranslationRevisionsTest::dataTestDecoupledPendingRevisions()
  2. 8.9.x core/tests/Drupal/KernelTests/Core/Entity/EntityDecoupledTranslationRevisionsTest.php \Drupal\KernelTests\Core\Entity\EntityDecoupledTranslationRevisionsTest::dataTestDecoupledPendingRevisions()
  3. 10 core/tests/Drupal/KernelTests/Core/Entity/EntityDecoupledTranslationRevisionsTest.php \Drupal\KernelTests\Core\Entity\EntityDecoupledTranslationRevisionsTest::dataTestDecoupledPendingRevisions()

Data provider for ::testDecoupledDefaultRevisions.

File

core/tests/Drupal/KernelTests/Core/Entity/EntityDecoupledTranslationRevisionsTest.php, line 112

Class

EntityDecoupledTranslationRevisionsTest
Test decoupled translation revisions.

Namespace

Drupal\KernelTests\Core\Entity

Code

public static function dataTestDecoupledPendingRevisions() {
    $sets = [];
    $sets['Intermixed languages - No initial default translation'][] = [
        [
            'en',
            TRUE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'en',
            TRUE,
        ],
        [
            'it',
            TRUE,
        ],
    ];
    $sets['Intermixed languages - With initial default translation'][] = [
        [
            'en',
            TRUE,
        ],
        [
            'it',
            TRUE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'en',
            TRUE,
        ],
        [
            'it',
            TRUE,
        ],
    ];
    $sets['Alternate languages - No initial default translation'][] = [
        [
            'en',
            TRUE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'en',
            TRUE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'en',
            TRUE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'it',
            TRUE,
        ],
    ];
    $sets['Alternate languages - With initial default translation'][] = [
        [
            'en',
            TRUE,
        ],
        [
            'it',
            TRUE,
        ],
        [
            'en',
            TRUE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'en',
            TRUE,
        ],
        [
            'it',
            TRUE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'it',
            TRUE,
        ],
    ];
    $sets['Multiple languages - No initial default translation'][] = [
        [
            'en',
            TRUE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'fr',
            FALSE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'en',
            TRUE,
        ],
        [
            'it',
            TRUE,
        ],
        [
            'fr',
            FALSE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'en',
            TRUE,
        ],
        [
            'fr',
            TRUE,
        ],
        [
            'it',
            TRUE,
        ],
        [
            'fr',
            TRUE,
        ],
    ];
    $sets['Multiple languages - With initial default translation'][] = [
        [
            'en',
            TRUE,
        ],
        [
            'it',
            TRUE,
        ],
        [
            'fr',
            TRUE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'en',
            TRUE,
        ],
        [
            'it',
            TRUE,
        ],
        [
            'fr',
            FALSE,
        ],
        [
            'en',
            FALSE,
        ],
        [
            'it',
            FALSE,
        ],
        [
            'en',
            TRUE,
        ],
        [
            'fr',
            TRUE,
        ],
        [
            'it',
            TRUE,
        ],
        [
            'fr',
            TRUE,
        ],
    ];
    return $sets;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.