You are here

protected function ArrayUnitTest::getWarningList in Coder 8.3.x

Same name and namespace in other branches
  1. 8.3 tests/Drupal/Arrays/ArrayUnitTest.php \Drupal\Test\Arrays\ArrayUnitTest::getWarningList()

Returns the lines where warnings should occur.

The key of the array should represent the line number and the value should represent the number of warnings that should occur on that line.

Parameters

string $testFile The name of the file being tested.:

Return value

array<int, int>

Overrides CoderSniffUnitTest::getWarningList

File

tests/Drupal/Arrays/ArrayUnitTest.php, line 56

Class

ArrayUnitTest

Namespace

Drupal\Test\Arrays

Code

protected function getWarningList(string $testFile) : array {
  switch ($testFile) {
    case 'ArrayUnitTest.inc':
      return [
        17 => 1,
        22 => 1,
        23 => 1,
        24 => 1,
        37 => 1,
        42 => 1,
        44 => 1,
        59 => 1,
        76 => 1,
      ];
  }
  return [];
}