From 6d37f007092971ddd0aa78663101c35d11074867 Mon Sep 17 00:00:00 2001 From: Luke Policinski Date: Tue, 23 May 2017 15:22:11 -0400 Subject: [PATCH] fixing tests , and code styles --- src/Illuminate/Pagination/LengthAwarePaginator.php | 2 +- src/Illuminate/Pagination/Paginator.php | 2 +- tests/Pagination/PaginatorTest.php | 5 ++--- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/Illuminate/Pagination/LengthAwarePaginator.php b/src/Illuminate/Pagination/LengthAwarePaginator.php index 374d6d6fbf88..ae7525bf3bed 100644 --- a/src/Illuminate/Pagination/LengthAwarePaginator.php +++ b/src/Illuminate/Pagination/LengthAwarePaginator.php @@ -170,7 +170,7 @@ public function toArray() 'from' => $this->firstItem(), 'to' => $this->lastItem(), 'data' => $this->items->toArray(), - 'path' => $this->path + 'path' => $this->path, ]; } diff --git a/src/Illuminate/Pagination/Paginator.php b/src/Illuminate/Pagination/Paginator.php index 64a9c559a609..1ae8b1879b02 100644 --- a/src/Illuminate/Pagination/Paginator.php +++ b/src/Illuminate/Pagination/Paginator.php @@ -149,7 +149,7 @@ public function toArray() 'from' => $this->firstItem(), 'to' => $this->lastItem(), 'data' => $this->items->toArray(), - 'path' => $this->path + 'path' => $this->path, ]; } diff --git a/tests/Pagination/PaginatorTest.php b/tests/Pagination/PaginatorTest.php index fa9431c56e3b..73eadeac83d6 100644 --- a/tests/Pagination/PaginatorTest.php +++ b/tests/Pagination/PaginatorTest.php @@ -9,8 +9,7 @@ class PaginatorTest extends TestCase { public function testSimplePaginatorReturnsRelevantContextInformation() { - $p = new Paginator($array = ['item3', 'item4', 'item5'], 2, 2, - ['path' => 'http://website.com/test']); + $p = new Paginator($array = ['item3', 'item4', 'item5'], 2, 2); $this->assertEquals(2, $p->currentPage()); $this->assertTrue($p->hasPages()); @@ -25,7 +24,7 @@ public function testSimplePaginatorReturnsRelevantContextInformation() 'from' => 3, 'to' => 4, 'data' => ['item3', 'item4'], - 'path' => 'http://website.com/test' + 'path' => '/', ]; $this->assertEquals($pageInfo, $p->toArray());