Files
hakorune/local_tests/test_socket_state_preservation.nyash
Moe Charm ef7a0de3b0 feat: Prepare for code modularization and cleanup
- Archive old documentation and test files to `docs/archive/` and `local_tests/`.
- Remove various temporary and old files from the project root.
- Add `nekocode-rust` analysis tool and its output files (`nekocode/`, `.nekocode_sessions/`, `analysis.json`).
- Minor updates to `apps/chip8_nyash/chip8_emulator.nyash` and `local_tests` files.

This commit cleans up the repository and sets the stage for further code modularization efforts, particularly in the `src/interpreter` and `src/parser` modules, based on recent analysis.
2025-08-16 01:30:39 +09:00

42 lines
1.5 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# PR #75 SocketBox状態保持テスト
# Arc<dyn NyashBox>修正効果の検証
static box Main {
init { console, server, result }
main() {
me.console = new ConsoleBox()
me.console.log("🔥 SocketBox状態保持テスト開始")
# SocketBox作成
me.server = new SocketBox()
me.console.log("✅ SocketBox作成完了")
# bind前のisServer確認
local isServerBefore = me.server.isServer()
me.console.log("Before bind: isServer = " + isServerBefore.toString())
# bind実行状態設定
local bindResult = me.server.bind("127.0.0.1", 18080)
me.console.log("Bind result = " + bindResult.toString())
# bind後のisServer確認🎯 重要これがtrueになるべき
local isServerAfter = me.server.isServer()
me.console.log("After bind: isServer = " + isServerAfter.toString())
# テスト結果判定
if isServerAfter.equals(true) {
me.console.log("🎉 SUCCESS: SocketBox状態保持修正完了!")
me.result = "PASS: State preservation works"
} else {
me.console.log("❌ FAILED: SocketBox状態が失われている")
me.result = "FAIL: State preservation broken"
}
# クリーンアップ
me.server.close()
me.console.log("🧹 SocketBox closed")
return me.result
}
}