mirror of
https://github.com/yiisoft/yii2.git
synced 2025-10-28 12:34:34 +08:00
Raise version min PHP 7.3.
This commit is contained in:
@ -20,14 +20,14 @@ class BaseObjectTest extends TestCase
|
||||
*/
|
||||
protected $object;
|
||||
|
||||
protected function setUp()
|
||||
protected function setUp(): void
|
||||
{
|
||||
parent::setUp();
|
||||
$this->mockApplication();
|
||||
$this->object = new NewObject();
|
||||
}
|
||||
|
||||
protected function tearDown()
|
||||
protected function tearDown(): void
|
||||
{
|
||||
parent::tearDown();
|
||||
$this->object = null;
|
||||
@ -159,19 +159,6 @@ class BaseObjectTest extends TestCase
|
||||
$this->expectExceptionMessage('Getting write-only property: yiiunit\framework\base\NewObject::writeOnly');
|
||||
$this->object->writeOnly;
|
||||
}
|
||||
|
||||
public function testBackwardCompatibilityWithObject()
|
||||
{
|
||||
if (PHP_MAJOR_VERSION > 7 || (PHP_MAJOR_VERSION == 7 && PHP_MINOR_VERSION >= 2)) {
|
||||
$this->markTestSkipped('This test is meant to run on PHP <7.2.0 to check BC with yii\base\Object');
|
||||
}
|
||||
$this->assertInstanceOf('yii\base\Object', new BCObject());
|
||||
$this->assertInstanceOf('yii\base\BaseObject', new BCObject());
|
||||
|
||||
BCObject::$initCalled = false;
|
||||
new BCObject();
|
||||
$this->assertTrue(BCObject::$initCalled);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user