From f649657841b95b51b1a3d74d1a941b3b8c0dc9b7 Mon Sep 17 00:00:00 2001 From: Ben Cromwell Date: Fri, 13 Mar 2020 09:11:59 +0000 Subject: [PATCH 1/3] Add PHP 7.4 targets to Travis CI --- .travis.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.travis.yml b/.travis.yml index 5402d9a9..fcbad963 100644 --- a/.travis.yml +++ b/.travis.yml @@ -54,6 +54,12 @@ matrix: - php: 7.3 env: - DEPS=latest + - php: 7.4 + env: + - DEPS=lowest + - php: 7.4 + env: + - DEPS=latest before_install: - if [[ $TEST_COVERAGE != 'true' ]]; then phpenv config-rm xdebug.ini || return 0 ; fi From 08c4b5a2cc3cf5083c0fb9b0cc87e593a9e1efca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Bundyra?= Date: Sun, 15 Mar 2020 10:54:21 +0000 Subject: [PATCH 2/3] Update PHPUnit versions and tests Use protected setUp and tearDown methods in tests. --- composer.json | 2 +- test/BindTest.php | 2 +- test/CanonTest.php | 2 +- test/ConnectTest.php | 2 +- test/ErrorHandlerTest.php | 2 +- test/OfflineReconnectTest.php | 2 +- test/OfflineTest.php | 2 +- test/ReconnectTest.php | 4 ++-- 8 files changed, 9 insertions(+), 9 deletions(-) diff --git a/composer.json b/composer.json index f050d8c7..7362e5fc 100644 --- a/composer.json +++ b/composer.json @@ -35,7 +35,7 @@ "laminas/laminas-eventmanager": "^2.6.3 || ^3.0.1", "laminas/laminas-stdlib": "^2.7 || ^3.0", "php-mock/php-mock-phpunit": "^1.1.2 || ^2.1.1", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.2" + "phpunit/phpunit": "^5.7.27 || ^6.5.14 || ^7.5.20" }, "suggest": { "laminas/laminas-eventmanager": "Laminas\\EventManager component" diff --git a/test/BindTest.php b/test/BindTest.php index 64ef5262..3e28bc71 100644 --- a/test/BindTest.php +++ b/test/BindTest.php @@ -29,7 +29,7 @@ class BindTest extends TestCase protected $altUsername; protected $bindRequiresDn = false; - public function setUp() + protected function setUp() { if (! getenv('TESTS_LAMINAS_LDAP_ONLINE_ENABLED')) { $this->markTestSkipped("Laminas_Ldap online tests are not enabled"); diff --git a/test/CanonTest.php b/test/CanonTest.php index 2fb42a30..fa46fa31 100644 --- a/test/CanonTest.php +++ b/test/CanonTest.php @@ -28,7 +28,7 @@ class CanonTest extends TestCase */ protected $options; - public function setUp() + protected function setUp() { if (! getenv('TESTS_LAMINAS_LDAP_ONLINE_ENABLED')) { $this->markTestSkipped("Laminas_Ldap online tests are not enabled"); diff --git a/test/ConnectTest.php b/test/ConnectTest.php index d569dfee..5b111c35 100644 --- a/test/ConnectTest.php +++ b/test/ConnectTest.php @@ -25,7 +25,7 @@ class ConnectTest extends TestCase { protected $options = null; - public function setUp() + protected function setUp() { if (! getenv('TESTS_LAMINAS_LDAP_ONLINE_ENABLED')) { $this->markTestSkipped("Laminas_Ldap online tests are not enabled"); diff --git a/test/ErrorHandlerTest.php b/test/ErrorHandlerTest.php index d8df5dcd..84e52ed8 100644 --- a/test/ErrorHandlerTest.php +++ b/test/ErrorHandlerTest.php @@ -23,7 +23,7 @@ class ErrorHandlerTest extends TestCase 'handleError', ]; - public function setUp() + protected function setUp() { /** @todo: remove when migrate to PHP 7.1+ and PHPUnit 7+ only */ if (class_exists(\PHPUnit_Util_ErrorHandler::class)) { diff --git a/test/OfflineReconnectTest.php b/test/OfflineReconnectTest.php index 92250129..a7241b88 100644 --- a/test/OfflineReconnectTest.php +++ b/test/OfflineReconnectTest.php @@ -20,7 +20,7 @@ protected function activateBindableOfflineMocks() BuiltinFunctionMocks::$ldap_set_option_mock->enable(); } - public function tearDown() + protected function tearDown() { parent::tearDown(); Mock::disableAll(); diff --git a/test/OfflineTest.php b/test/OfflineTest.php index ec17c1e9..8e9d5a01 100644 --- a/test/OfflineTest.php +++ b/test/OfflineTest.php @@ -37,7 +37,7 @@ class OfflineTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { $this->ldap = new Ldap\Ldap(); } diff --git a/test/ReconnectTest.php b/test/ReconnectTest.php index 0afe86a4..d7e76524 100644 --- a/test/ReconnectTest.php +++ b/test/ReconnectTest.php @@ -47,7 +47,7 @@ protected static function getStandardOptions() return $options; } - public function setUp() + protected function setUp() { if (! getenv('TESTS_LAMINAS_LDAP_ONLINE_ENABLED')) { $this->markTestSkipped("Laminas_Ldap online tests are not enabled"); @@ -56,7 +56,7 @@ public function setUp() $this->getLDAP()->setOptions(static::getStandardOptions()); } - public function tearDown() + protected function tearDown() { // Make sure we're using a non-expired connection with known settings // for each test. From 914284cda2633302d4ab1831ce0f5962187ad980 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Bundyra?= Date: Sun, 15 Mar 2020 10:54:37 +0000 Subject: [PATCH 3/3] Adds CHANGELOG entry for #8 --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ff3ef49f..91a1d688 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,7 +6,7 @@ All notable changes to this project will be documented in this file, in reverse ### Added -- Nothing. +- [#8](https://github.com/laminas/laminas-ldap/pull/8) adds support for PHP 7.4. ### Changed