Fix WASM Jump/Branch implementation and HTTPServer listen() functionality
Co-authored-by: moe-charm <217100418+moe-charm@users.noreply.github.com>
This commit is contained in:
20
test_socket_direct.nyash
Normal file
20
test_socket_direct.nyash
Normal file
@ -0,0 +1,20 @@
|
||||
// Test SocketBox directly
|
||||
static box Main {
|
||||
init { socket, console }
|
||||
|
||||
main() {
|
||||
me.socket = new SocketBox()
|
||||
me.console = new ConsoleBox()
|
||||
|
||||
// Test bind and listen operations directly on SocketBox
|
||||
local bindResult = me.socket.bind("127.0.0.1", 8080)
|
||||
me.console.log("SocketBox Bind result:")
|
||||
print(bindResult)
|
||||
|
||||
local listenResult = me.socket.listen(10)
|
||||
me.console.log("SocketBox Listen result:")
|
||||
print(listenResult)
|
||||
|
||||
return listenResult
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user