Skip to content

AgenticCMSに対応#4433

Open
ryuring wants to merge 14 commits into
baserproject:5.4.xfrom
ryuring:dev-agentic
Open

AgenticCMSに対応#4433
ryuring wants to merge 14 commits into
baserproject:5.4.xfrom
ryuring:dev-agentic

Conversation

@ryuring

@ryuring ryuring commented Jun 20, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

@ryuring

ryuring commented Jun 21, 2026

Copy link
Copy Markdown
Collaborator Author

@copilot resolve the merge conflicts in this pull request

@ryuring ryuring closed this Jun 21, 2026
@ryuring ryuring reopened this Jun 21, 2026
@ryuring

ryuring commented Jun 21, 2026

Copy link
Copy Markdown
Collaborator Author

@copilot resolve the merge conflicts in this pull request

ryuring and others added 9 commits June 21, 2026 13:03
DB を全 drop して再マイグレーションするテスト/インストール処理の再作成対象に
BcMcp が含まれず、oauth2 系テーブルが復活しないため OAuth2 系テストが 500 になっていた。

- bc-installer InstallationsAdminServiceTest::test_deleteAllTables の再作成リストに BcMcp を追加
- BcInstaller の testStep3(createDb) は defaultInstall のみ作り直すため、BcMcp の testsuite を
  BcInstaller より前(BcSeo の後)へ移動(phpunit.xml.dist)
- コアプラグインコンバートスキルに知見を追記(複数のマイグレーション再作成リスト/testsuite 順序)
- 外部依存取り込みに伴う composer.lock 更新

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
testIntegration / testIntegrationWithPKCE は実 MCP サーバー(SSE)が必要で、
CI(GitHub Actions)ではバックグラウンドサーバーを起動・到達できず 500 になる。
サーバー起動を該当2テストに限定し、起動できなければ markTestSkipped する
(サーバーのある環境では実行、CI では安全にスキップ)。スキルにも知見を追記。

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
isServerRunning() は pidファイル+プロセス生存のみで、ポート bind 完了を保証しない。
CI ではプロセス起動後にポート bind が間に合わず、プロキシが 127.0.0.1:{port} へ
接続できず 500 になっていた。requireMcpServer() を fsockopen による実接続待ち
(最大15秒ポーリング)に変更し、到達できればテスト実行、到達不可なら markTestSkipped。

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
markTestSkipped はサーバー起動不具合を隠して CI を緑にしてしまうため、
実ポート到達待ち(最大15秒)後に到達できなければ assertTrue で明示的に失敗させる。
サーバーが立てばテストは実行・検証され、立たなければ赤で検知できる。

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
外部プロセス(MCPサーバー等)を要するテストは、該当テスト側で起動し、
プロセス存在でなく実接続到達まで待ち、到達不可なら skip せず明示的に失敗させる方針を
.github/instructions/basercms.instructions.md に記載。コアプラグイン変換スキルも同方針へ更新。

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
CI で MCP サーバーが起動しない原因を切り分けるため、127.0.0.1:{port} へ到達できない
場合は bc_mcp_server.log の末尾を失敗メッセージに添える。コマンド未登録・DB未接続・
ポート競合などの起動失敗理由が CI 出力に現れるようにする。

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
サーバー子プロセス bin/cake bc_mcp.server は default 接続の plugins テーブル
(status=true)から有効プラグインをロードする。BcMcp は defaultInstall 外のため
bin/cake install では有効化されず、CI で bc_mcp.server コマンドが未登録=起動失敗
→プロキシ500 になっていた。requireMcpServer() の冒頭で BcMcp を plugins へ
有効化(既存ならスキップ)してから起動する。test.yml は変更しないテスト完結の対応。

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
CI のサーバー子プロセスは BcEnv.isInstalled=false により baserCMS がプラグインを
ロードせず bc_mcp.server コマンドが未登録で起動できなかった。インストール状態に
依存せず BcMcp を明示ロードするテスト専用ランチャ(tests/mcp_test_server.php)経由で
SSE サーバーを起動するよう変更。到達待ち+失敗時の起動ログ出力は維持。

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants