diff --git a/composer.json b/composer.json index 8594a91..18750ba 100644 --- a/composer.json +++ b/composer.json @@ -11,13 +11,13 @@ } ], "require": { - "php": ">=7.2|^8.0", + "php": "^8.0", "ext-gd": "*", - "bacon/bacon-qr-code": "^2.0" + "bacon/bacon-qr-code": "^3.0" }, "require-dev": { "mockery/mockery": "~1", - "phpunit/phpunit": "~9" + "phpunit/phpunit": "~11.5" }, "suggest": { "ext-imagick": "Allows the generation of PNG QrCodes.", diff --git a/tests/DataTypes/BTCTest.php b/tests/DataTypes/BTCTest.php index 04b3e49..2613ef3 100644 --- a/tests/DataTypes/BTCTest.php +++ b/tests/DataTypes/BTCTest.php @@ -5,6 +5,8 @@ class BTCTest extends TestCase { + private BTC $btc; + public function setUp(): void { $this->btc = new BTC(); @@ -34,8 +36,8 @@ public function test_it_generates_a_valid_btc_qrcode_with_an_address_amount_labe 'btcaddress', 0.0034, [ - 'label' => 'label', - 'message' => 'message', + 'label' => 'label', + 'message' => 'message', 'returnAddress' => 'https://www.returnaddress.com', ], ]); diff --git a/tests/DataTypes/EmailTest.php b/tests/DataTypes/EmailTest.php index 17a6931..42e5631 100644 --- a/tests/DataTypes/EmailTest.php +++ b/tests/DataTypes/EmailTest.php @@ -5,6 +5,8 @@ class EmailTest extends TestCase { + private Email $email; + public function setUp(): void { $this->email = new Email(); diff --git a/tests/DataTypes/SMSTest.php b/tests/DataTypes/SMSTest.php index 42a6e43..d129a2f 100644 --- a/tests/DataTypes/SMSTest.php +++ b/tests/DataTypes/SMSTest.php @@ -5,6 +5,8 @@ class SMSTest extends TestCase { + private SMS $sms; + public function setUp(): void { $this->sms = new SMS(); diff --git a/tests/DataTypes/WiFiTest.php b/tests/DataTypes/WiFiTest.php index 246e1bf..8735b76 100644 --- a/tests/DataTypes/WiFiTest.php +++ b/tests/DataTypes/WiFiTest.php @@ -5,9 +5,11 @@ class WiFiTest extends TestCase { + private WiFi $wifi; + public function setUp(): void { - $this->wifi = new Wifi(); + $this->wifi = new WiFi(); } public function test_it_generates_a_proper_format_with_just_the_ssid() @@ -27,7 +29,7 @@ public function test_it_generates_a_proper_format_for_a_ssid_that_is_hidden() { $this->wifi->create([ 0 => [ - 'ssid' => 'foo', + 'ssid' => 'foo', 'hidden' => 'true', ], ]); @@ -41,9 +43,9 @@ public function test_it_generates_a_proper_format_for_a_ssid_encryption_and_pass { $this->wifi->create([ 0 => [ - 'ssid' => 'foo', + 'ssid' => 'foo', 'encryption' => 'WPA', - 'password' => 'bar', + 'password' => 'bar', ], ]); @@ -56,10 +58,10 @@ public function test_it_generates_a_proper_format_for_a_ssid_encryption_password { $this->wifi->create([ 0 => [ - 'ssid' => 'foo', + 'ssid' => 'foo', 'encryption' => 'WPA', - 'password' => 'bar', - 'hidden' => 'true', + 'password' => 'bar', + 'hidden' => 'true', ], ]); diff --git a/tests/GeneratorTest.php b/tests/GeneratorTest.php index d0d75be..91536a2 100644 --- a/tests/GeneratorTest.php +++ b/tests/GeneratorTest.php @@ -197,7 +197,7 @@ public function test_get_renderer_returns_renderer() public function test_it_calls_a_valid_dynamic_method_and_generates_a_qrcode() { $result = (new Generator)->btc('1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa'); - $this->assertEquals("\n\n", $result); + $this->assertEquals("\n\n", $result); } public function test_it_throws_an_exception_if_datatype_is_not_found()