Skip to content
This repository was archived by the owner on Mar 12, 2025. It is now read-only.

PHP Syntax Fixes #30

Merged
merged 2 commits into from
May 17, 2018
Merged
Show file tree
Hide file tree
Changes from all 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
2 changes: 1 addition & 1 deletion src/Constraint/CrawlerNot.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ protected function fail($nodes, $selector, ComparisonFailure $comparisonFailure
);
}

public function toString()
public function toString() : string
{
if ($this->string) {
return 'that contains text "' . $this->string . '"';
Expand Down
2 changes: 1 addition & 1 deletion src/Constraint/JsonContains.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ protected function matches($other) : bool
*
* @return string
*/
public function toString()
public function toString() : string
{
//unused
return '';
Expand Down
2 changes: 1 addition & 1 deletion src/Constraint/JsonType.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ protected function matches($jsonArray) : bool
*
* @return string
*/
public function toString()
public function toString() : string
{
//unused
return '';
Expand Down
2 changes: 1 addition & 1 deletion src/Constraint/WebDriverNot.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ protected function fail($nodes, $selector, ComparisonFailure $comparisonFailure
);
}

public function toString()
public function toString() : string
{
if ($this->string) {
return 'that contains text "' . $this->string . '"';
Expand Down
2 changes: 1 addition & 1 deletion src/ResultPrinter/UI.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ protected function printDefectTrace(\PHPUnit\Framework\TestFailure $defect): voi
$this->write($defect->getExceptionAsString());
$this->writeNewLine();

$stackTrace = \PHPUnit\Util\Filter::getFilteredStacktrace($defect->thrownException(), false);
$stackTrace = \PHPUnit\Util\Filter::getFilteredStacktrace($defect->thrownException());

foreach ($stackTrace as $i => $frame) {
if (!isset($frame['file'])) {
Expand Down