Skip to content

Commit 0a65b3a

Browse files
committed
chore: add missing ext-sodium in suggest
1 parent bcc9b54 commit 0a65b3a

File tree

4 files changed

+25
-1
lines changed

4 files changed

+25
-1
lines changed

admin/framework/composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
"ext-readline": "Improves CLI::input() usability",
4444
"ext-redis": "If you use Cache class RedisHandler",
4545
"ext-simplexml": "If you format XML",
46+
"ext-sodium" => "If you Encryption SodiumHandler",
4647
"ext-sqlite3": "If you use SQLite3",
4748
"ext-sqlsrv": "If you use SQL Server",
4849
"ext-xdebug": "If you use CIUnitTestCase::assertHeaderEmitted()"

composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@
5252
"ext-readline": "Improves CLI::input() usability",
5353
"ext-redis": "If you use Cache class RedisHandler",
5454
"ext-simplexml": "If you format XML",
55+
"ext-sodium": "If you Encryption SodiumHandler",
5556
"ext-sqlite3": "If you use SQLite3",
5657
"ext-sqlsrv": "If you use SQL Server",
5758
"ext-xdebug": "If you use CIUnitTestCase::assertHeaderEmitted()"

system/Database/Config.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,8 @@ public static function forge($group = null)
112112
/**
113113
* Returns a new instance of the Database Utilities class.
114114
*
115-
* @param array|string|null $group
115+
* @param array|BaseConnection|non-empty-string|null $group The name of the connection group to use,
116+
* or an array of configuration settings.
116117
*
117118
* @return BaseUtils
118119
*/

tests/system/Models/UpdateModelTest.php

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -375,6 +375,27 @@ public function testUpdateWithEntityNoAllowedFields(): void
375375
$this->model->update($id, $entity);
376376
}
377377

378+
public function testUpdateWithEntity(): void
379+
{
380+
$this->createModel(UserModel::class);
381+
382+
$entity = new class () extends Entity {
383+
};
384+
$entity->id = 1;
385+
$entity->name = 'Jones Martin';
386+
$entity->email = '[email protected]';
387+
$entity->country = 'India';
388+
389+
$id = $this->model->insert($entity);
390+
391+
$user = $this->model->asObject(get_class($entity))->find($id);
392+
393+
$user->country = 'id';
394+
$result = $this->model->save($user);
395+
396+
$this->assertTrue($result);
397+
}
398+
378399
public function testUseAutoIncrementSetToFalseUpdate(): void
379400
{
380401
$key = 'key';

0 commit comments

Comments
 (0)