Raise version min PHP 7.3.

This commit is contained in:
Wilmer Arambula
2024-03-20 17:27:20 -03:00
parent e2a167028b
commit ce813e5060
189 changed files with 1901 additions and 1586 deletions

View File

@ -55,7 +55,7 @@ class CommandTest extends \yiiunit\framework\db\CommandTest
$command = $db->createCommand($sql);
$intCol = 123;
$charCol = 'abc';
$floatCol = 1.23;
$floatCol = 1.230;
$blobCol = "\x10\x11\x12";
$numericCol = '1.23';
$boolCol = false;
@ -69,9 +69,10 @@ class CommandTest extends \yiiunit\framework\db\CommandTest
$sql = 'SELECT int_col, char_col, float_col, CONVERT([nvarchar], blob_col) AS blob_col, numeric_col FROM type';
$row = $db->createCommand($sql)->queryOne();
$this->assertEquals($intCol, $row['int_col']);
$this->assertEquals($charCol, trim($row['char_col']));
$this->assertEquals($floatCol, $row['float_col']);
$this->assertEquals($floatCol, (float) $row['float_col']);
$this->assertEquals($blobCol, $row['blob_col']);
$this->assertEquals($numericCol, $row['numeric_col']);
@ -113,7 +114,7 @@ class CommandTest extends \yiiunit\framework\db\CommandTest
$this->assertEmpty($schema->getTableDefaultValues($tableName, true));
$db->createCommand()->addDefaultValue($name, $tableName, 'int1', 41)->execute();
$this->assertRegExp('/^.*41.*$/', $schema->getTableDefaultValues($tableName, true)[0]->value);
$this->assertMatchesRegularExpression('/^.*41.*$/', $schema->getTableDefaultValues($tableName, true)[0]->value);
$db->createCommand()->dropDefaultValue($name, $tableName)->execute();
$this->assertEmpty($schema->getTableDefaultValues($tableName, true));

View File

@ -5,7 +5,7 @@
* @license https://www.yiiframework.com/license/
*/
namespace yiiunit\framework\db\mssql\Type;
namespace yiiunit\framework\db\mssql\type;
use yii\db\Query;
use yiiunit\framework\db\DatabaseTestCase;