[4.x]: Outdated Testing Docs
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 40/100
- issue の種類
- ドキュメント
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- php
- 領域
- documentation, testing
調査の方向性
まず、issue で参照されている Craft 4 のテストドキュメントを見つけ、そこにある Codeception、dotenv、Craft CMS、およびコマンドの例を、報告された PHP 8 のセットアップと比較します。影響を受ける手順を更新して、インストールとテスト実行に一貫性を持たせ、その後、報告された失敗と照らし合わせて、ドキュメントに記載されたコマンドと依存関係を検証します。
索引モデルが issue の本文から書いたものです。
説明
What happened?
Description
Following the Craft 4 testing documentation I noticed a few inconsitencies which indicate that it has not been updated since Craft 3.
Problem 1: Install Codeception 3.1 or Higher. Running composer require --dev codeception/codeception ^3.1 will prompt this: - codeception/codeception[3.1.0, ..., 3.1.3] require php >=5.6.0 <8.0 -> your php version (8.0.2; overridden via config.platform, actual: 8.0.30) does not satisfy that requirement. CraftCMs requries >=8.0.2, this version of codeception requires <8.0.
In the requirements section, this is written: Craft CMS 3.2 or higher, however, I am using the Craft 4 docs. This is probably the biggest give away that the docs have no been updated.
Problem 2: Running composer require --dev vlucas/phpdotenv ^3.0, will result in the following error when running ./craft: PHP Fatal error: Uncaught Error: Call to undefined method Dotenv\Dotenv::createUnsafeMutable() in /Users/.../.../.../craft2/bootstrap.php:17
Problem 3: codecept is not in project root path. Must to use php vendor/bin/codecept run Unit.
Taking the assumption that both codeception/codeception and vlucas/phpdotenv should be installed at their latest version to continue.
Running php vendor/bin/codecept run Unit results in the following error:
Codeception PHP Testing Framework v5.0.11 https://helpukrainewin.org
PHP Fatal error: Uncaught Error: Class "Codeception\Module\Yii2" not found in /Users/.../.../.../craft/vendor/craftcms/cms/src/test/Craft.php:65
Stack trace:
#0 /Users/.../.../.../craft/vendor/composer/ClassLoader.php(576): include()
craftcms/cms#1 /Users/.../.../.../craft/vendor/composer/ClassLoader.php(427): Composer\Autoload\{closure}('/Users/.../...')
craftcms/cms#2 [internal function]: Composer\Autoload\ClassLoader->loadClass('craft\\test\\Craf...')
craftcms/cms#3 /Users/.../.../.../craft/vendor/codeception/codeception/src/Codeception/Lib/ModuleContainer.php(97): class_exists('\\craft\\test\\Cra...')
craftcms/cms#4 /Users/.../.../.../craft/vendor/codeception/codeception/src/Codeception/SuiteManager.php(49): Codeception\Lib\ModuleContainer->create('\\craft\\test\\Cra...')
Craft CMS version
4.5.5
PHP version
8.0.30
Operating system and version
Mac OS Ventura 13.0
Database type and version
MySQL Ver 14.14 Distrib 5.7.42
Image driver and version
No response
Installed plugins and versions
"require": {
"craftcms/cms": "^4.4.0",
"vlucas/phpdotenv": "^5.4.0"
},
"require-dev": {
"codeception/codeception": "^5.0",
"craftcms/generator": "^1.3.0",
"yiisoft/yii2-shell": "^2.0.3",
"codeception/module-phpbrowser": "*",
"codeception/module-asserts": "*"
},
- 主要言語
- JavaScript
- スター
- 43
- フォーク
- 160
- 平均マージ
- 3時間 57分
- マージ済み PR(30日)
- 3
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
craftcms/docs のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
-
Broken Link対応中かも @PerceiveWorld が 142 日前に担当しました。 オープンBroken Link
難易度 1/5 1時間未満 初心者へのやさしさ 72/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
-
難易度 1/5 1〜3時間 初心者へのやさしさ 68/100
-
Broken LinkオープンBroken Link
難易度 1/5 1時間未満 初心者へのやさしさ 68/100
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 71/100
yjh051108/dsh-routing-suite#227 ·
-
needs-triage release-watch
難易度 1/5 1時間未満 初心者へのやさしさ 76/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
dusk-network/exu#17 ·
-
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
jspreadsheet/ce#1809 ·
-
documentation
難易度 1/5 1時間未満 初心者へのやさしさ 91/100
githubnext/gh-aw-workshop#4458 ·
メンテナーはふだん 1 日以内に返信