Php8.2 fix in test
authorEileen McNaughton <emcnaughton@wikimedia.org>
Sun, 12 Mar 2023 22:46:46 +0000 (11:46 +1300)
committerEileen McNaughton <emcnaughton@wikimedia.org>
Sun, 12 Mar 2023 22:46:46 +0000 (11:46 +1300)
tests/phpunit/CRM/Pledge/Form/SearchTest.php

index a074d68798c535caa9dfd99374415ff5146a585a..e23baab56d8edc1b66a9d75dbc3e4c0a53bdef36 100644 (file)
@@ -8,8 +8,7 @@ class CRM_Pledge_Form_SearchTest extends CiviUnitTestCase {
 
   public function setUp(): void {
     parent::setUp();
-    $this->individualID = $this->individualCreate();
-    $this->pledgeCreate(['contact_id' => $this->individualID]);
+    $this->pledgeCreate(['contact_id' => $this->individualCreate()]);
   }
 
   public function tearDown(): void {
@@ -25,7 +24,7 @@ class CRM_Pledge_Form_SearchTest extends CiviUnitTestCase {
   /**
    *  Test submitted the search form.
    */
-  public function testSearch() {
+  public function testSearch(): void {
     $form = new CRM_Pledge_Form_Search();
     $_SERVER['REQUEST_METHOD'] = 'GET';
     $form->controller = new CRM_Pledge_Controller_Search();