tests: Add socket_connect test

This commit is contained in:
sleepycatcoding 2023-07-23 20:44:15 +03:00 committed by Nathan Adams
parent 809e511656
commit d52f2a4409
5 changed files with 44 additions and 0 deletions

View File

@ -0,0 +1,24 @@
package
{
import flash.display.Sprite;
public class Test extends Sprite
{
}
}
import flash.events.Event;
import flash.net.Socket;
var socket:Socket = new Socket();
socket.addEventListener(Event.CONNECT, function(event:Event):void
{
trace("connected");
socket.writeUTF("Hello!");
socket.flush();
socket.close();
});
socket.connect("localhost", 8001);

View File

@ -0,0 +1 @@
connected

View File

@ -0,0 +1,18 @@
[
{
"type": "Receive",
"expected": [
0,
6,
72,
101,
108,
108,
111,
33
]
},
{
"type": "WaitForDisconnect"
}
]

Binary file not shown.

View File

@ -0,0 +1 @@
num_ticks = 10