Skip to content

Commit 27a14d8

Browse files
committed
Coding standards for tests
1 parent 9a58979 commit 27a14d8

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

tests/ConvertKitAPITest.php

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ class ConvertKitAPITest extends TestCase
1616

1717
/**
1818
* Location of the monologger log file.
19-
*
19+
*
2020
* @since 1.2.0
21-
*
21+
*
2222
* @var string
2323
*/
2424
protected $logFile = '';
@@ -38,7 +38,7 @@ protected function setUp(): void
3838
$dotenv->load();
3939

4040
// Set location where API class will create/write the log file.
41-
$this->logFile = dirname(dirname(__FILE__)).'/src/logs/debug.log';
41+
$this->logFile = dirname(dirname(__FILE__)) . '/src/logs/debug.log';
4242

4343
// Delete any existing debug log file.
4444
$this->deleteLogFile();
@@ -49,9 +49,9 @@ protected function setUp(): void
4949

5050
/**
5151
* Test that debug logging works when enabled and an API call is made.
52-
*
52+
*
5353
* @since 1.2.0
54-
*
54+
*
5555
* @return void
5656
*/
5757
public function testDebugEnabled()
@@ -67,15 +67,15 @@ public function testDebugEnabled()
6767

6868
/**
6969
* Test that debug logging is not performed when disabled and an API call is made.
70-
*
70+
*
7171
* @since 1.2.0
72-
*
72+
*
7373
* @return void
7474
*/
7575
public function testDebugDisabled()
7676
{
7777
$result = $this->api->get_account();
78-
78+
7979
// Confirm that the log is empty / doesn't exist.
8080
$this->assertEmpty($this->getLogFileContents());
8181
}
@@ -2085,29 +2085,29 @@ public function testGetResourceInaccessibleURL()
20852085

20862086
/**
20872087
* Deletes the src/logs/debug.log file, if it remains following a previous test.
2088-
*
2088+
*
20892089
* @since 1.2.0
2090-
*
2090+
*
20912091
* @return void
20922092
*/
20932093
private function deleteLogFile()
20942094
{
2095-
if(file_exists($this->logFile)) {
2095+
if (file_exists($this->logFile)) {
20962096
unlink($this->logFile);
20972097
}
20982098
}
20992099

21002100
/**
21012101
* Returns the contents of the src/logs/debug.log file.
2102-
*
2102+
*
21032103
* @since 1.2.0
2104-
*
2104+
*
21052105
* @return string
21062106
*/
21072107
private function getLogFileContents()
21082108
{
21092109
// Return blank string if no log file.
2110-
if(!file_exists($this->logFile)) {
2110+
if (!file_exists($this->logFile)) {
21112111
return '';
21122112
}
21132113

0 commit comments

Comments
 (0)