From 1cbfdb4d233abe79e179a9ff176eec22ff248866 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Fri, 6 Mar 2026 11:15:27 +0000 Subject: [PATCH 1/3] Initial plan From d122c04985e070d5f9853a4f23eee18fa400ead0 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Fri, 6 Mar 2026 11:27:52 +0000 Subject: [PATCH 2/3] Add PHP 7.4 and 8.0 support Co-authored-by: daedeloth <1168599+daedeloth@users.noreply.github.com> --- .github/workflows/tests.yml | 2 +- composer.json | 4 ++-- phpunit.xml | 9 +-------- tests/DbQueryTest.php | 3 +-- 4 files changed, 5 insertions(+), 13 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 989f50a..ddb5ba2 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -15,7 +15,7 @@ jobs: strategy: matrix: - php-version: ['8.1', '8.2', '8.3'] + php-version: ['7.4', '8.0', '8.1', '8.2', '8.3'] name: PHP ${{ matrix.php-version }} diff --git a/composer.json b/composer.json index c2c4f85..9a5553c 100644 --- a/composer.json +++ b/composer.json @@ -15,13 +15,13 @@ ], "require" : { - "php": ">=8.1.0", + "php": ">=7.4", "ext-gettext" : "*", "nesbot/carbon": "^2.0||^3.0" }, "require-dev": { - "phpunit/phpunit": "^10.0||^11.0" + "phpunit/phpunit": "^9.5||^10.0||^11.0" }, "autoload": { diff --git a/phpunit.xml b/phpunit.xml index 216c033..45a41da 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -1,13 +1,6 @@ - - - - src/Neuron - - + colors="true"> diff --git a/tests/DbQueryTest.php b/tests/DbQueryTest.php index 8a924ae..c5e0a34 100644 --- a/tests/DbQueryTest.php +++ b/tests/DbQueryTest.php @@ -3,14 +3,13 @@ namespace Neuron\Tests; use PHPUnit\Framework\TestCase; -use PHPUnit\Framework\Attributes\Group; use Neuron\DB\Query; /** * Class DbQueryTest * @package Neuron\Tests + * @group database */ -#[Group('database')] class DbQueryTest extends TestCase { /** From e158dc31f1674488c409509966117674045910cc Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Fri, 6 Mar 2026 12:20:46 +0000 Subject: [PATCH 3/3] Fix PHP 7.4 bool comparison: use strict equality in checkInput() Co-authored-by: daedeloth <1168599+daedeloth@users.noreply.github.com> --- src/Neuron/Core/Tools.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Neuron/Core/Tools.php b/src/Neuron/Core/Tools.php index 740af75..8b7ce28 100755 --- a/src/Neuron/Core/Tools.php +++ b/src/Neuron/Core/Tools.php @@ -72,7 +72,7 @@ public static function checkInput ($value, $type) elseif ($type == 'bool') { - return $value == 1 || $value == 'true'; + return $value === 1 || $value === '1' || $value === 'true'; } elseif ($type == 'varchar' || $type == 'string' || $type == 'html')