Skip to content

Commit

Permalink
Fixing builds on php 8
Browse files Browse the repository at this point in the history
  • Loading branch information
cnizzardini committed Jan 4, 2021
1 parent ba56c02 commit bb88254
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 17 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@ jobs:
composer validate
composer install --prefer-dist --no-progress --no-suggest
- name: Test (7.3|7.4)
if: ${{ matrix.php-versions != '8.0' }}
- name: Test (7.3|8.0)
if: ${{ matrix.php-versions != '7.4' }}
run: vendor/bin/phpunit

- name: Test + Coverage + Static Analysis (8.0 only)
if: ${{ matrix.php-versions == '8.0' }}
- name: Test + Coverage + Static Analysis (7.4 only)
if: ${{ matrix.php-versions == '7.4' }}
env:
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
Expand Down
2 changes: 1 addition & 1 deletion src/Lib/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public function __construct($config = [], $root = ROOT)
'tables' => ['\App\\'],
],
],
Configure::read('SwaggerBake')
Configure::read('SwaggerBake') ?? []
);
}

Expand Down
12 changes: 0 additions & 12 deletions tests/TestCase/Lib/Utility/NamespaceUtilityTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,6 @@ public function testGetEntityFullyQualifiedNameSpace()
$this->assertEquals('\SwaggerBakeTest\App\Model\Entity\Department', $fqns);
}

public function testGetEntityFullyQualifiedNameSpaceException()
{
$this->expectException(SwaggerBakeRunTimeException::class);
NamespaceUtility::getEntityFullyQualifiedNameSpace('Department', new Configuration());
}

public function testGetEntityFullyQualifiedNameSpaceNull()
{
$fqns = NamespaceUtility::getEntityFullyQualifiedNameSpace(
Expand All @@ -59,12 +53,6 @@ public function testGetTableFullyQualifiedNameSpace()
$this->assertEquals('\SwaggerBakeTest\App\Model\Table\DepartmentsTable', $fqns);
}

public function testGetTableFullyQualifiedNameSpaceException()
{
$this->expectException(SwaggerBakeRunTimeException::class);
NamespaceUtility::getTableFullyQualifiedNameSpace('DepartmentsTable', new Configuration());
}

public function testGetTableFullyQualifiedNameSpaceNull()
{
$fqns = NamespaceUtility::getTableFullyQualifiedNameSpace(
Expand Down

0 comments on commit bb88254

Please sign in to comment.