Last active
August 29, 2015 13:57
-
-
Save jeregrine/9478481 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 1) test Initates a connection proper. (Phoenix.Router.RawWebsocketHandlerTest) | |
| ** (UndefinedFunctionError) undefined function: Socket.TCP.packet!/2 | |
| stacktrace: | |
| Socket.TCP.packet!(:raw, {Socket.TCP, #Port<0.20319>, nil, {:resource, 305923944, ""}}) | |
| lib/socket/web.ex:210: Socket.Web.connect!/3 | |
| lib/socket/web.ex:140: Socket.Web.connect/3 | |
| test/phoenix/websocket_handler_test.exs:24: Phoenix.Router.RawWebsocketHandlerTest."test Initates a connection proper."/1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| defmodule Phoenix.Router.RawWebsocketHandlerTest do | |
| use ExUnit.Case | |
| use PlugHelper | |
| defmodule EchoHandler do | |
| use Phoenix.Websocket.RawHandler | |
| def stream(data, socket, _state) do | |
| reply socket, data | |
| end | |
| end | |
| defmodule Router do | |
| use Phoenix.Router, port: 5000 | |
| raw_websocket "/echo", EchoHandler | |
| end | |
| setup do | |
| {:ok, server: Router.start} | |
| end | |
| test "Initates a connection proper." do | |
| {:ok, sock} = Socket.Web.connect("localhost", 5000, path: "/echo") | |
| end | |
| teardown meta do | |
| meta[:server].stop | |
| end | |
| end |
no Socket.Manager process running
Hi, knewter.
I met same problem. Do you have any solutions?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
https://github.com/meh/elixir-socket/blob/master/lib/socket/tcp.ex#L136