diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 1f0d9a4..f112d40 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -9,27 +9,27 @@ jobs: strategy: fail-fast: true matrix: - php: [7.4] - laravel: [6.*] + php: [8.2, 8.3, 8.4] + laravel: [12.*] dependency-version: [prefer-lowest, prefer-stable] include: - - laravel: 6.* - testbench: 4.* + - laravel: 12.* + testbench: 10.* name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.dependency-version }} steps: - name: Checkout code - uses: actions/checkout@v1 + uses: actions/checkout@v4 - name: Cache dependencies - uses: actions/cache@v1 + uses: actions/cache@v4 with: path: ~/.composer/cache/files key: dependencies-laravel-${{ matrix.laravel }}-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }} - name: Setup PHP - uses: shivammathur/setup-php@v1 + uses: shivammathur/setup-php@v2 with: php-version: ${{ matrix.php }} extension-csv: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick diff --git a/composer.json b/composer.json index 7f6f964..115bff2 100644 --- a/composer.json +++ b/composer.json @@ -16,11 +16,16 @@ } ], "require": { - "php": "^7.3 || ^8.0" + "php": "^8.2", + "illuminate/support": "^12.0", + "illuminate/database": "^12.0", + "illuminate/contracts": "^12.0", + "nesbot/carbon": "^3.0" }, "require-dev": { - "symfony/var-dumper": "^4.3 || ^5.1 || ^6.0", - "phpunit/phpunit": "^8.2 || ^9.3" + "orchestra/testbench": "^10.0", + "phpunit/phpunit": "^11.0", + "symfony/var-dumper": "^7.0" }, "autoload": { "psr-4": { diff --git a/database/migrations/create_wallet_plus_tables.php.stub b/database/migrations/create_wallet_plus_tables.php.stub index 5f1337e..dafc3b6 100644 --- a/database/migrations/create_wallet_plus_tables.php.stub +++ b/database/migrations/create_wallet_plus_tables.php.stub @@ -4,7 +4,7 @@ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; -class CreateWalletPlusTables extends Migration +return new class extends Migration { /** * Run the migrations. @@ -53,4 +53,4 @@ class CreateWalletPlusTables extends Migration Schema::dropIfExists('wallets'); Schema::dropIfExists('wallet_ledgers'); } -} +}; diff --git a/phpunit.xml.dist b/phpunit.xml.dist index dc6a98a..9e84fc4 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -1,29 +1,17 @@ - + - + tests - - + + src/ - - - - - - - - - + + diff --git a/src/WalletPlusServiceProvider.php b/src/WalletPlusServiceProvider.php index 54db70b..aced97e 100644 --- a/src/WalletPlusServiceProvider.php +++ b/src/WalletPlusServiceProvider.php @@ -11,7 +11,7 @@ class WalletPlusServiceProvider extends ServiceProvider /** * Bootstrap the application services. */ - public function boot(Filesystem $filesystem) + public function boot(Filesystem $filesystem): void { $this->publishes([ __DIR__ . '/../database/migrations/create_wallet_plus_tables.php.stub' => @@ -22,7 +22,7 @@ public function boot(Filesystem $filesystem) /** * Register the application services. */ - public function register() + public function register(): void { // $this->mergeConfigFrom(__DIR__ . '/../config/config.php', 'wallet-plus'); }