Skip to content

Commit

Permalink
upgrade to Laravel 11 and PHPUnit 10
Browse files Browse the repository at this point in the history
  • Loading branch information
manuel-watchenterprise authored and mdpoulter committed Jun 16, 2024
1 parent ed978fc commit ae75aa3
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 24 deletions.
8 changes: 4 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,16 @@
"require": {
"php": "^8.0",
"bensampo/laravel-enum": "^5.0 || ^6.0",
"illuminate/support": "^9.0 || ^10.0",
"illuminate/support": "^9.0 || ^10.0 || ^11.0",
"laravel/nova": "^4.0"
},
"require-dev": {
"joshgaber/novaunit": "^3.1",
"laravel/pint": "^1.2",
"mockery/mockery": "^1.3.3",
"nunomaduro/collision": "^6.1 || ^7.0",
"orchestra/testbench": "^7.0 || ^8.0",
"phpunit/phpunit": "^9.3.3",
"nunomaduro/collision": "^6.1 || ^7.0 || ^8.0",
"orchestra/testbench": "^7.0 || ^8.0 || ^9.0",
"phpunit/phpunit": "^10.0",
"symfony/var-dumper": "^6.0"
},
"autoload": {
Expand Down
38 changes: 19 additions & 19 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="./vendor/phpunit/phpunit/phpunit.xsd"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.5/phpunit.xsd"
bootstrap="vendor/autoload.php"
colors="true">
<coverage>
<include>
<directory suffix=".php">src</directory>
</include>
</coverage>
<testsuites>
<testsuite name="Simple Squid Test Suite">
<directory>tests/Fields</directory>
<directory>tests/Filters</directory>
</testsuite>
</testsuites>
<php>
<env name="DB_CONNECTION" value="mysql"/>
<env name="DB_USERNAME" value="root"/>
<env name="DB_DATABASE" value="nova_enum_field"/>
<env name="DB_HOST" value="127.0.0.1"/>
<env name="DB_PORT" value="3306"/>
</php>
<testsuites>
<testsuite name="Simple Squid Test Suite">
<directory>tests/Fields</directory>
<directory>tests/Filters</directory>
</testsuite>
</testsuites>
<php>
<env name="DB_CONNECTION" value="mysql"/>
<env name="DB_USERNAME" value="root"/>
<env name="DB_DATABASE" value="nova_enum_field"/>
<env name="DB_HOST" value="127.0.0.1"/>
<env name="DB_PORT" value="3306"/>
</php>
<source>
<include>
<directory suffix=".php">src</directory>
</include>
</source>
</phpunit>
3 changes: 2 additions & 1 deletion tests/Fields/FieldTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ public function it_starts_with_no_options_and_rules()
/** @test */
public function it_allows_an_enum_to_be_attached()
{
$this->assertObjectHasAttribute('optionsCallback', $this->field);
$this->assertIsObject($this->field);
$this->assertTrue(property_exists($this->field, 'optionsCallback'));
}

/** @test */
Expand Down

0 comments on commit ae75aa3

Please sign in to comment.