Test tidy ups, formatting, casing
authoreileen <emcnaughton@wikimedia.org>
Tue, 7 Feb 2017 03:24:16 +0000 (16:24 +1300)
committereileen <emcnaughton@wikimedia.org>
Tue, 7 Feb 2017 03:38:35 +0000 (16:38 +1300)
tests/phpunit/CRM/Contact/BAO/QueryTest.php

index 5c014f30b8e676405b6ca9318c064beaacc726e4..8111339be4b158909155cff1cd7166357cc8a91d 100644 (file)
@@ -349,17 +349,20 @@ class CRM_Contact_BAO_QueryTest extends CiviUnitTestCase {
       "display_name" => 1,
       "preferred_mail_format" => 1,
     );
-    $numberofContacts = 2;
+    $numberOfContacts = 2;
     $query = new CRM_Contact_BAO_Query($params, $returnProperties);
     try {
-      $query->apiQuery($params, $returnProperties, NULL, NULL, 0, $numberofContacts);
+      $query->apiQuery($params, $returnProperties, NULL, NULL, 0, $numberOfContacts);
     }
     catch (Exception $e) {
-      $this->assertEquals("A fatal error was triggered: One of parameters  (value: foo@example.com) is not of the type Positive",
-        $e->getMessage());
-      return $this->assertTrue(TRUE);
+      $this->assertEquals(
+        "A fatal error was triggered: One of parameters  (value: foo@example.com) is not of the type Positive",
+        $e->getMessage()
+      );
+      $this->assertTrue(TRUE);
+      return;
     }
-    return $this->fail('Test failed for some reason which is not good');
+    $this->fail('Test failed for some reason which is not good');
   }
 
 }