Add deploy test.

This commit is contained in:
James Murdza 2024-07-23 22:17:36 -04:00
parent 7ed19188d4
commit 02ea851fb7

View File

@ -11,7 +11,7 @@ interface CallbackResponse {
} }
let socketRef: Socket = io( let socketRef: Socket = io(
`http://localhost:4000?userId=user_2hFB6KcK6bb3Gx9241UXsxFq4kO&sandboxId=aabuk4vneecj2csni24kpabv`, `http://localhost:4000?userId=user_2hFB6KcK6bb3Gx9241UXsxFq4kO&sandboxId=v30a2c48xal03tzio7mapt19`,
{ {
timeout: 2000, timeout: 2000,
} }
@ -28,6 +28,14 @@ socketRef.on("connect", async () => {
console.log("Error:", response.message); console.log("Error:", response.message);
} }
}); });
socketRef.emit("deploy", (response: CallbackResponse) => {
if (response.success) {
console.log("It worked!");
} else {
console.log("Error:", response.message);
}
});
}); });
socketRef.on("disconnect", () => { socketRef.on("disconnect", () => {