- Extend plugin-tester to support multi-box plugins with v2 API - Add nyash_plugin_get_box_count/get_box_info/get_type_id functions - Create test multi-box plugin providing TestBoxA and TestBoxB - Update plugin-system.md documentation for v2 format - Add nyash.toml v2 specification for multi-box support - Successfully tested multi-box plugin lifecycle and type resolution This enables one plugin to provide multiple Box types, solving the dependency issue where HTTPServerBox needs SocketBox. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
28 lines
884 B
Plaintext
28 lines
884 B
Plaintext
// 🌐 HttpClientBox簡単テスト
|
|
static box Main {
|
|
init { http, console }
|
|
|
|
main() {
|
|
me.console = new ConsoleBox()
|
|
me.console.log("🌐 HTTP通信テスト開始...")
|
|
|
|
// HttpClientBoxを作成
|
|
me.http = new HttpClientBox()
|
|
|
|
// 1. 簡単なGETリクエスト
|
|
me.console.log("📥 GET: https://httpbin.org/get")
|
|
local getResult = me.http.get("https://httpbin.org/get")
|
|
me.console.log("結果: " + getResult.toString())
|
|
|
|
// 2. POSTリクエスト
|
|
me.console.log("")
|
|
me.console.log("📤 POST: https://httpbin.org/post")
|
|
local postResult = me.http.post(
|
|
"https://httpbin.org/post",
|
|
"Hello from Nyash!"
|
|
)
|
|
me.console.log("結果: " + postResult.toString())
|
|
|
|
return "✅ HTTPテスト完了"
|
|
}
|
|
} |