From e3e68576ae636f082613822b0f133fd35f049f86 Mon Sep 17 00:00:00 2001 From: DBX12 Date: Sat, 16 Oct 2021 11:17:51 +0200 Subject: [PATCH 1/2] Annotate thrown exceptions with FQN --- src/Codeception/Module/Yii2.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Codeception/Module/Yii2.php b/src/Codeception/Module/Yii2.php index bd710a4..47b382e 100644 --- a/src/Codeception/Module/Yii2.php +++ b/src/Codeception/Module/Yii2.php @@ -423,7 +423,7 @@ public function _parts() * Requires the `user` component to be enabled and configured. * * @param $user - * @throws ModuleException + * @throws \Codeception\Exception\ModuleException */ public function amLoggedInAs($user) { @@ -521,7 +521,7 @@ function ($fixturesStore) { * * @param $name * @return mixed - * @throws ModuleException if the fixture is not found + * @throws \Codeception\Exception\ModuleException if the fixture is not found * @part fixtures */ public function grabFixture($name, $index = null) @@ -714,7 +714,7 @@ protected function clientRequest($method, $uri, array $parameters = [], array $f * * @param $component * @return mixed - * @throws ModuleException + * @throws \Codeception\Exception\ModuleException * @deprecated in your tests you can use \Yii::$app directly. */ public function grabComponent($component) @@ -739,7 +739,7 @@ public function grabComponent($component) * ``` * * @param int $num - * @throws ModuleException + * @throws \Codeception\Exception\ModuleException * @part email */ public function seeEmailIsSent($num = null) @@ -775,7 +775,7 @@ public function dontSeeEmailIsSent() * * @part email * @return array - * @throws ModuleException + * @throws \Codeception\Exception\ModuleException */ public function grabSentEmails() { From 4030bfe03ed7fcb10ad1f20fb8b847930356a439 Mon Sep 17 00:00:00 2001 From: DBX12 Date: Sat, 16 Oct 2021 11:19:20 +0200 Subject: [PATCH 2/2] Fix documentation of Module\Yii2::setCookie() Documentation described a `$value` parameter, function signature had `$val` as parameter name. --- src/Codeception/Module/Yii2.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Codeception/Module/Yii2.php b/src/Codeception/Module/Yii2.php index 47b382e..a21d20f 100644 --- a/src/Codeception/Module/Yii2.php +++ b/src/Codeception/Module/Yii2.php @@ -826,7 +826,7 @@ private function defineConstants() /** * Sets a cookie and, if validation is enabled, signs it. * @param string $name The name of the cookie - * @param string $value The value of the cookie + * @param string $val The value of the cookie * @param array $params Additional cookie params like `domain`, `path`, `expires` and `secure`. */ public function setCookie($name, $val, array $params = [])