diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 19730f9..0e58d36 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -3,25 +3,41 @@ name: run-tests on: workflow_dispatch: push: - branches: [main, develop] + branches: + - main + - develop pull_request: - branches: [main, develop] + branches: + - main + - develop jobs: test: runs-on: ${{ matrix.os }} + strategy: fail-fast: true matrix: os: [ubuntu-latest] - php: [8.1, 8.2] - laravel: [9.*, 10.*] + php: [8.1, 8.2, 8.3] + laravel: ['9.*', '10.*', '11.*', '12.*'] stability: [prefer-stable] include: - laravel: 9.* testbench: ^7.10 - laravel: 10.* testbench: ^8.0 + - laravel: 11.* + testbench: ^9.0 + - laravel: 12.* + testbench: ^10.0 + exclude: + - laravel: 9.* + php: 8.3 + - laravel: 11.* + php: 8.1 + - laravel: 12.* + php: 8.1 name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }} - ${{ matrix.os }} @@ -50,6 +66,4 @@ jobs: run: vendor/bin/phpunit - name: Codecov - # You may pin to the exact commit or the version. - # uses: codecov/codecov-action@d9f34f8cd5cb3b3eb79b3e4b5dae3a16df499a70 uses: codecov/codecov-action@v3.1.4 diff --git a/composer.json b/composer.json index effadcb..716403d 100644 --- a/composer.json +++ b/composer.json @@ -18,11 +18,11 @@ ], "require": { "php": "^8.0|^8.1|^8.2", - "illuminate/contracts": "^8.0|^9.0|^10.0" + "illuminate/contracts": "^8.0|^9.0|^10.0|^11.0|^12.0" }, "require-dev": { - "orchestra/testbench": "^6.22|^7.0|^8.0", - "phpunit/phpunit": "^9.5|^10.0", + "orchestra/testbench": "^6.22|^7.0|^8.0|^9.0|^10.0", + "phpunit/phpunit": "^9.5|^10.0|^11.5.3", "squizlabs/php_codesniffer": "*" }, "autoload": { @@ -52,7 +52,7 @@ "providers": [ "LucasDotVin\\Soulbscription\\SoulbscriptionServiceProvider" ], - "aliases": {} + "aliases": [] } }, "minimum-stability": "stable", diff --git a/database/migrations/2022_02_01_233701_create_plans_table.php b/database/migrations/2022_02_01_233701_create_plans_table.php index 5b4cc97..14ce62f 100644 --- a/database/migrations/2022_02_01_233701_create_plans_table.php +++ b/database/migrations/2022_02_01_233701_create_plans_table.php @@ -16,7 +16,7 @@ public function up() $table->id(); $table->integer('grace_days')->default(0); $table->string('name'); - $table->unsignedInteger('periodicity')->nullable(); + $table->integer('periodicity')->unsigned()->nullable(); $table->string('periodicity_type')->nullable(); $table->softDeletes(); $table->timestamps(); diff --git a/database/migrations/2022_02_01_235540_create_features_table.php b/database/migrations/2022_02_01_235540_create_features_table.php index 5745c77..273b0a9 100644 --- a/database/migrations/2022_02_01_235540_create_features_table.php +++ b/database/migrations/2022_02_01_235540_create_features_table.php @@ -18,7 +18,7 @@ public function up() $table->boolean('consumable'); $table->boolean('quota')->default(false); $table->boolean('postpaid')->default(false); - $table->unsignedInteger('periodicity')->nullable(); + $table->integer('periodicity')->unsigned()->nullable(); $table->string('periodicity_type')->nullable(); $table->softDeletes(); $table->timestamps(); diff --git a/database/migrations/2022_02_02_000527_create_feature_consumptions_table.php b/database/migrations/2022_02_02_000527_create_feature_consumptions_table.php index 6660ae4..526eb92 100644 --- a/database/migrations/2022_02_02_000527_create_feature_consumptions_table.php +++ b/database/migrations/2022_02_02_000527_create_feature_consumptions_table.php @@ -14,7 +14,7 @@ public function up() { Schema::create('feature_consumptions', function (Blueprint $table) { $table->id(); - $table->unsignedDecimal('consumption')->nullable(); + $table->decimal('consumption')->unsigned()->nullable(); $table->timestamp('expired_at')->nullable(); $table->foreignIdFor(\LucasDotVin\Soulbscription\Models\Feature::class)->constrained()->cascadeOnDelete(); $table->timestamps();