Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Last set of PHP-CS-Fixer updates #875

Merged
merged 4 commits into from
Feb 13, 2020
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 4 additions & 7 deletions .php_cs.dist
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,9 @@ return PhpCsFixer\Config::create()
'protected_to_private' => false,
'self_accessor' => false,

// Should be included in @PhpCsFixer / @PhpCsFixer:risky according to doc, but need to be
// enabled manually for some reason.
'fopen_flags' => true,
'multiline_whitespace_before_semicolons' => true,
'native_function_invocation' => true,

// Additional rules
'fopen_flags' => true,
'linebreak_after_opening_tag' => true,
]);
'native_function_invocation' => true,
])
;
6 changes: 4 additions & 2 deletions tests/Stripe/StripeTelemetryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ public function testNoTelemetrySentIfNotEnabled()
$stub = $this
->getMockBuilder('HttpClient\\ClientInterface')
->setMethods(['request'])
->getMock();
->getMock()
;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seriously you want to make me mad right?


$stub->expects(static::any())
->method('request')
Expand Down Expand Up @@ -75,7 +76,8 @@ public function testTelemetrySetIfEnabled()
$stub = $this
->getMockBuilder('HttpClient\\ClientInterface')
->setMethods(['request'])
->getMock();
->getMock()
;

$stub->expects(static::any())
->method('request')
Expand Down
9 changes: 6 additions & 3 deletions tests/TestHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,8 @@ function ($method, $absUrl, $headers, $params, $hasFile) {

return $curlClient->request($method, $absUrl, $headers, $params, $hasFile);
}
);
)
;
}

/**
Expand Down Expand Up @@ -124,7 +125,8 @@ protected function stubRequest(
$base = null
) {
$this->prepareRequestMock($method, $path, $params, $headers, $hasFile, $base)
->willReturn([\json_encode($response), $rcode, []]);
->willReturn([\json_encode($response), $rcode, []])
;
}

/**
Expand Down Expand Up @@ -179,6 +181,7 @@ private function prepareRequestMock(
}),
null === $params ? static::anything() : static::identicalTo($params),
static::identicalTo($hasFile)
);
)
;
}
}