From f0072622c382953633a32fcf6a82cc26ca239db4 Mon Sep 17 00:00:00 2001
From: eiriksm <eiriksm@1014468.no-reply.drupal.org>
Date: Mon, 23 Aug 2021 12:50:53 +0000
Subject: [PATCH] Issue #3229410 by eiriksm: Fix phpstan errors

---
 drupalci.yml                           | 49 ++++++++++++++++++++++++++
 tests/src/Kernel/DateProcessorTest.php | 10 ------
 2 files changed, 49 insertions(+), 10 deletions(-)
 create mode 100644 drupalci.yml

diff --git a/drupalci.yml b/drupalci.yml
new file mode 100644
index 0000000..c04a296
--- /dev/null
+++ b/drupalci.yml
@@ -0,0 +1,49 @@
+# This is the DrupalCI testbot build file.
+# Learn to make one for your own drupal.org project:
+# https://www.drupal.org/drupalorg/docs/drupal-ci/customizing-drupalci-testing
+build:
+  assessment:
+    validate_codebase:
+      phplint:
+      phpcs:
+        # phpcs will use core's specified version of Coder.
+        sniff-all-files: true
+        halt-on-fail: true
+      phpstan:
+        halt-on-fail: true
+    testing:
+      # run_tests task is executed several times in order of performance speeds.
+      # halt-on-fail can be set on the run_tests tasks in order to fail fast.
+      # suppress-deprecations is false in order to be alerted to usages of
+      # deprecated code.
+      run_tests.phpunit:
+        types: 'PHPUnit-Unit'
+        testgroups: '--all'
+        suppress-deprecations: false
+        halt-on-fail: false
+      run_tests.kernel:
+        types: 'PHPUnit-Kernel'
+        testgroups: '--all'
+        suppress-deprecations: true
+        halt-on-fail: false
+      run_tests.simpletest:
+        types: 'Simpletest'
+        testgroups: '--all'
+        suppress-deprecations: false
+        halt-on-fail: false
+      run_tests.functional:
+        types: 'PHPUnit-Functional'
+        testgroups: '--all'
+        suppress-deprecations: false
+        halt-on-fail: false
+      # Functional JavaScript tests require a concurrency of 1 because there is
+      # only one instance of PhantomJS on the testbot machine.
+      run_tests.javascript:
+        concurrency: 1
+        types: 'PHPUnit-FunctionalJavascript'
+        testgroups: '--all'
+        suppress-deprecations: false
+        halt-on-fail: false
+      # Run nightwatch testing.
+      # @see https://www.drupal.org/project/drupal/issues/2869825
+      nightwatchjs:
diff --git a/tests/src/Kernel/DateProcessorTest.php b/tests/src/Kernel/DateProcessorTest.php
index cf8d00f..ecf7dd6 100644
--- a/tests/src/Kernel/DateProcessorTest.php
+++ b/tests/src/Kernel/DateProcessorTest.php
@@ -118,14 +118,4 @@ class DateProcessorTest extends KernelTestBase {
     self::assertNotEmpty($json->extra->elasticsearch_date);
   }
 
-  /**
-   * Helper.
-   */
-  protected function getRecordAfterProcessor($record) {
-    // Just make sure the extra key is there.
-    $record['extra'] = [];
-    $processor = $this->processor;
-    return $processor($record);
-  }
-
 }
-- 
GitLab