diff --git a/tests/framework/base/ActionFilterTest.php b/tests/framework/base/ActionFilterTest.php
index <HASH>..<HASH> 100644
--- a/tests/framework/base/ActionFilterTest.php
+++ b/tests/framework/base/ActionFilterTest.php
@@ -238,7 +238,7 @@ class Filter3 extends ActionFilter
 
 class MockUser extends User
 {
-    public function init()
+    public function init(): void
     {
         // do not call parent to avoid the need to mock configuration
     }
diff --git a/tests/framework/helpers/JsonTest.php b/tests/framework/helpers/JsonTest.php
index <HASH>..<HASH> 100644
--- a/tests/framework/helpers/JsonTest.php
+++ b/tests/framework/helpers/JsonTest.php
@@ -11,7 +11,7 @@ use yii\base\DynamicModel;
 use yii\helpers\BaseJson;
 use yii\helpers\Json;
 use yii\web\JsExpression;
-use yii\web\tests\Post;
+use yii\web\tests\stubs\Post;
 use yii\tests\TestCase;
 
 /**
Fixing tests after changes in `yii-web` package