From ebdb5c15f26b2874e5cb21d2bcb5fc70a777bb23 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Tamarelle?= Date: Wed, 27 Aug 2025 20:59:04 +0200 Subject: [PATCH] Remove calls to ReflectionProperty::setAccessible(true) (#1761) --- tests/Collection/CollectionFunctionalTest.php | 2 -- tests/Database/DatabaseFunctionalTest.php | 2 -- 2 files changed, 4 deletions(-) diff --git a/tests/Collection/CollectionFunctionalTest.php b/tests/Collection/CollectionFunctionalTest.php index 1c7af5be3..d937f7bee 100644 --- a/tests/Collection/CollectionFunctionalTest.php +++ b/tests/Collection/CollectionFunctionalTest.php @@ -404,7 +404,6 @@ public function testWithOptionsInheritsOptions(): void $rc = new ReflectionClass($clone); $rp = $rc->getProperty('autoEncryptionEnabled'); - $rp->setAccessible(true); $this->assertSame(true, $rp->getValue($clone)); } @@ -432,7 +431,6 @@ public function testWithOptionsPassesOptions(): void $rc = new ReflectionClass($clone); $rp = $rc->getProperty('autoEncryptionEnabled'); - $rp->setAccessible(true); $this->assertSame(true, $rp->getValue($clone)); } diff --git a/tests/Database/DatabaseFunctionalTest.php b/tests/Database/DatabaseFunctionalTest.php index 07f383ee1..fa9d9c926 100644 --- a/tests/Database/DatabaseFunctionalTest.php +++ b/tests/Database/DatabaseFunctionalTest.php @@ -397,7 +397,6 @@ public function testWithOptionsInheritsOptions(): void $rc = new ReflectionClass($clone); $rp = $rc->getProperty('autoEncryptionEnabled'); - $rp->setAccessible(true); $this->assertSame(true, $rp->getValue($clone)); } @@ -424,7 +423,6 @@ public function testWithOptionsPassesOptions(): void $rc = new ReflectionClass($clone); $rp = $rc->getProperty('autoEncryptionEnabled'); - $rp->setAccessible(true); $this->assertSame(true, $rp->getValue($clone)); }