Laravel 5.6 updates

Travis config update

Removed HHVM script as Laravel no longer support HHVM after releasing 5.3
This commit is contained in:
Manish Verma
2018-08-06 20:08:55 +05:30
parent 126fbb0255
commit 1ac0f42a58
2464 changed files with 65239 additions and 46734 deletions

View File

@@ -19,26 +19,14 @@ use Symfony\Component\VarDumper\Dumper\CliDumper;
*/
trait VarDumperTestTrait
{
public function assertDumpEquals($dump, $data, $filter = 0, $message = '')
public function assertDumpEquals($expected, $data, $filter = 0, $message = '')
{
if (\is_string($filter)) {
@trigger_error(sprintf('The $message argument of the "%s()" method at the 3rd position is deprecated since Symfony 3.4 and will be moved at the 4th position in 4.0.', __METHOD__), E_USER_DEPRECATED);
$message = $filter;
$filter = 0;
}
$this->assertSame(rtrim($dump), $this->getDump($data, null, $filter), $message);
$this->assertSame($this->prepareExpectation($expected, $filter), $this->getDump($data, null, $filter), $message);
}
public function assertDumpMatchesFormat($dump, $data, $filter = 0, $message = '')
public function assertDumpMatchesFormat($expected, $data, $filter = 0, $message = '')
{
if (\is_string($filter)) {
@trigger_error(sprintf('The $message argument of the "%s()" method at the 3rd position is deprecated since Symfony 3.4 and will be moved at the 4th position in 4.0.', __METHOD__), E_USER_DEPRECATED);
$message = $filter;
$filter = 0;
}
$this->assertStringMatchesFormat(rtrim($dump), $this->getDump($data, null, $filter), $message);
$this->assertStringMatchesFormat($this->prepareExpectation($expected, $filter), $this->getDump($data, null, $filter), $message);
}
protected function getDump($data, $key = null, $filter = 0)
@@ -57,4 +45,13 @@ trait VarDumperTestTrait
return rtrim($dumper->dump($data, true));
}
private function prepareExpectation($expected, $filter)
{
if (!\is_string($expected)) {
$expected = $this->getDump($expected, null, $filter);
}
return rtrim($expected);
}
}