Fix notices in phpunit
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" backupGlobals="false" bootstrap="vendor/autoload.php" colors="true" processIsolation="false" stopOnFailure="false" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/11.2/phpunit.xsd" cacheDirectory=".phpunit.cache" backupStaticProperties="false">
|
||||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" backupGlobals="false" bootstrap="vendor/autoload.php" colors="true" processIsolation="false" stopOnFailure="false" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/11.2/phpunit.xsd">
|
||||
<testsuites>
|
||||
<testsuite name="Feature">
|
||||
<directory suffix="Test.php">./tests/Feature</directory>
|
||||
@@ -16,9 +16,9 @@
|
||||
<env name="QUEUE_DRIVER" value="sync"/>
|
||||
<env name="APP_KEY" value="value_from_phpunit"/>
|
||||
</php>
|
||||
<source>
|
||||
<coverage>
|
||||
<include>
|
||||
<directory suffix=".php">./app</directory>
|
||||
</include>
|
||||
</source>
|
||||
</coverage>
|
||||
</phpunit>
|
||||
|
||||
@@ -71,6 +71,7 @@ class ConversationChangeCustomerTest extends TestCase
|
||||
* This is the regression test for the authorization bypass where changeCustomer()
|
||||
* executed unconditionally even when permission checks set an error message.
|
||||
*/
|
||||
#[RequiresPhp('>=8.3.0')]
|
||||
public function testUnauthorizedUserCannotChangeCustomer()
|
||||
{
|
||||
$response = $this->actingAs($this->unprivUser)
|
||||
@@ -98,6 +99,7 @@ class ConversationChangeCustomerTest extends TestCase
|
||||
* Test that an authorized admin user CAN change a conversation's customer.
|
||||
* This ensures the fix does not break normal functionality.
|
||||
*/
|
||||
#[RequiresPhp('>=8.3.0')]
|
||||
public function testAuthorizedUserCanChangeCustomer()
|
||||
{
|
||||
$response = $this->actingAs($this->admin)
|
||||
|
||||
Reference in New Issue
Block a user