From 71dd726e4193b2aa2ab0bb51a2f78cd7eed8c30f Mon Sep 17 00:00:00 2001 From: Filip Horvat Date: Thu, 26 Mar 2020 10:02:37 +0100 Subject: [PATCH 1/2] revert tests --- tests/Tests/AggregateJoinTest.php | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/tests/Tests/AggregateJoinTest.php b/tests/Tests/AggregateJoinTest.php index 6acc9c9..8fe3dc1 100644 --- a/tests/Tests/AggregateJoinTest.php +++ b/tests/Tests/AggregateJoinTest.php @@ -8,20 +8,13 @@ class AggregateJoinTest extends TestCase { - public function setUp(): void - { - $this->markTestSkipped('skip for now.'); - } - - private $queryTest = 'select orders.*, SUM(sellers.id) as sort + private $queryTest = 'select orders.*, SUM("sellers"."id") as sort from "orders" left join "sellers" on "sellers"."id" = "orders"."seller_id" where "orders"."deleted_at" is null group by "orders"."id" order by sort asc'; - private $bindingsTest = ['sellers.id']; - public function testAvg() { Order::joinRelations('seller') @@ -30,7 +23,6 @@ public function testAvg() $queryTest = str_replace(EloquentJoinBuilder::AGGREGATE_SUM, EloquentJoinBuilder::AGGREGATE_SUM, $this->queryTest); $this->assertQueryMatches($queryTest, $this->fetchQuery()); - $this->assertEquals($this->bindingsTest, $this->fetchBindings()); } public function testSum() @@ -41,7 +33,6 @@ public function testSum() $queryTest = str_replace(EloquentJoinBuilder::AGGREGATE_SUM, EloquentJoinBuilder::AGGREGATE_AVG, $this->queryTest); $this->assertQueryMatches($queryTest, $this->fetchQuery()); - $this->assertEquals($this->bindingsTest, $this->fetchBindings()); } public function testMax() @@ -52,7 +43,6 @@ public function testMax() $queryTest = str_replace(EloquentJoinBuilder::AGGREGATE_SUM, EloquentJoinBuilder::AGGREGATE_MAX, $this->queryTest); $this->assertQueryMatches($queryTest, $this->fetchQuery()); - $this->assertEquals($this->bindingsTest, $this->fetchBindings()); } public function testMin() @@ -63,7 +53,6 @@ public function testMin() $queryTest = str_replace(EloquentJoinBuilder::AGGREGATE_SUM, EloquentJoinBuilder::AGGREGATE_MIN, $this->queryTest); $this->assertQueryMatches($queryTest, $this->fetchQuery()); - $this->assertEquals($this->bindingsTest, $this->fetchBindings()); } public function testCount() @@ -74,6 +63,5 @@ public function testCount() $queryTest = str_replace(EloquentJoinBuilder::AGGREGATE_SUM, EloquentJoinBuilder::AGGREGATE_COUNT, $this->queryTest); $this->assertQueryMatches($queryTest, $this->fetchQuery()); - $this->assertEquals($this->bindingsTest, $this->fetchBindings()); } } From 6d8ed0c52efbb95a89642706fddabfd60c47f883 Mon Sep 17 00:00:00 2001 From: Filip Horvat Date: Thu, 26 Mar 2020 10:07:40 +0100 Subject: [PATCH 2/2] update test yml ... --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index df0832b..e8db2e3 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,7 +12,7 @@ jobs: strategy: matrix: php_version: [7.2] - laravel_version: [5.*,6.*, 7.*] + laravel_version: [5.5.*,6.*, 7.*] steps: - name: Checkout commit