Skip to content

Instantly share code, notes, and snippets.

@bcardarella
Created February 27, 2016 19:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bcardarella/aaa48aedf208a8f05496 to your computer and use it in GitHub Desktop.
Save bcardarella/aaa48aedf208a8f05496 to your computer and use it in GitHub Desktop.
1) test retrieve a weekly status that doesn't exist (HowWeDoin.Api.WeeklyStatusReplyTest)
test/api/weekly_status_reply_test.exs:29
** (FunctionClauseError) no function clause matching in Plug.Conn.resp/3
stacktrace:
(plug) lib/plug/conn.ex:439: Plug.Conn.resp(%Plug.Conn{adapter: {Plug.Adapters.Test.Conn, :...}, assigns: %{layout: false}, before_send: [#Function<0.32851098/1 in JaSerializer.ContentTypeNegotiation.set_content_type/2>, #Function<1.847247/1 in Plug.Logger.call/2>], body_params: %{}, cookies: %Plug.Conn.Unfetched{aspect: :cookies}, halted: false, host: "www.example.com", method: "GET", owner: #PID<0.270.0>, params: %{"reply_id" => "123", "reply_token" => "1234567890"}, path_info: ["api", "sessions", "reply"], peer: {{127, 0, 0, 1}, 111317}, port: 80, private: %{HowWeDoin.Router => {[], %{}}, :phoenix_action => :create, :phoenix_controller => HowWeDoin.SessionController, :phoenix_endpoint => HowWeDoin.Endpoint, :phoenix_format => "json-api", :phoenix_layout => {HowWeDoin.LayoutView, :app}, :phoenix_pipelines => [:api], :phoenix_recycled => true, :phoenix_route => #Function<1.44589438/1 in HowWeDoin.Router.match_route/4>, :phoenix_router => HowWeDoin.Router, :phoenix_template => "unauthorized.json-api", :phoenix_view => HowWeDoin.SessionView, :plug_session_fetch => #Function<0.21388074/1 in Plug.Session.fetch_session/1>, :plug_skip_csrf_protection => true}, query_params: %{"reply_id" => "123", "reply_token" => "1234567890"}, query_string: "reply_id=123&reply_token=1234567890", remote_ip: {127, 0, 0, 1}, req_cookies: %Plug.Conn.Unfetched{aspect: :cookies}, req_headers: [{"accept", "application/vnd.api+json"}, {"content-type", "application/vnd.api+json"}], request_path: "/api/sessions/reply", resp_body: nil, resp_cookies: %{}, resp_headers: [{"content-type", "application/vnd.api+json; charset=utf-8"}, {"cache-control", "max-age=0, private, must-revalidate"}, {"x-request-id", "bhd95hi7iqtmjaoc9dk3n6v0vo38c5ju"}], scheme: :http, script_name: [], secret_key_base: "95bLxwzq6dwjySDiMxa/z7hWCzzCdMlnJROgZYZpNc5D13WmQKWQ3MdoQkQThtPg", state: :unset, status: 401}, 401, %{})
(plug) lib/plug/conn.ex:429: Plug.Conn.send_resp/3
(how_we_doin) web/controllers/session_controller.ex:1: HowWeDoin.SessionController.action/2
(how_we_doin) web/controllers/session_controller.ex:1: HowWeDoin.SessionController.phoenix_controller_pipeline/2
(how_we_doin) lib/phoenix/router.ex:261: HowWeDoin.Router.dispatch/2
(how_we_doin) web/router.ex:1: HowWeDoin.Router.do_call/2
(how_we_doin) lib/how_we_doin/endpoint.ex:1: HowWeDoin.Endpoint.phoenix_pipeline/1
(how_we_doin) lib/phoenix/endpoint/render_errors.ex:34: HowWeDoin.Endpoint.call/2
(phoenix) lib/phoenix/test/conn_test.ex:194: Phoenix.ConnTest.dispatch/5
test/api/weekly_status_reply_test.exs:30
2) test retrieve a weekly status that has been replied to (HowWeDoin.Api.WeeklyStatusReplyTest)
test/api/weekly_status_reply_test.exs:24
** (FunctionClauseError) no function clause matching in Plug.Conn.resp/3
stacktrace:
(plug) lib/plug/conn.ex:439: Plug.Conn.resp(%Plug.Conn{adapter: {Plug.Adapters.Test.Conn, :...}, assigns: %{layout: false}, before_send: [#Function<0.32851098/1 in JaSerializer.ContentTypeNegotiation.set_content_type/2>, #Function<1.847247/1 in Plug.Logger.call/2>], body_params: %{}, cookies: %Plug.Conn.Unfetched{aspect: :cookies}, halted: false, host: "www.example.com", method: "GET", owner: #PID<0.271.0>, params: %{"reply_id" => "480806839", "reply_token" => "$2b$04$8/eV4aSlRxnAyblPRL1PT.asIrTyhbNALVqVyReTG3NVrC5nBeXz."}, path_info: ["api", "sessions", "reply"], peer: {{127, 0, 0, 1}, 111317}, port: 80, private: %{HowWeDoin.Router => {[], %{}}, :phoenix_action => :create, :phoenix_controller => HowWeDoin.SessionController, :phoenix_endpoint => HowWeDoin.Endpoint, :phoenix_format => "json-api", :phoenix_layout => {HowWeDoin.LayoutView, :app}, :phoenix_pipelines => [:api], :phoenix_recycled => true, :phoenix_route => #Function<1.44589438/1 in HowWeDoin.Router.match_route/4>, :phoenix_router => HowWeDoin.Router, :phoenix_template => "unauthorized.json-api", :phoenix_view => HowWeDoin.SessionView, :plug_session_fetch => #Function<0.21388074/1 in Plug.Session.fetch_session/1>, :plug_skip_csrf_protection => true}, query_params: %{"reply_id" => "480806839", "reply_token" => "$2b$04$8/eV4aSlRxnAyblPRL1PT.asIrTyhbNALVqVyReTG3NVrC5nBeXz."}, query_string: "reply_id=480806839&reply_token=%242b%2404%248%2FeV4aSlRxnAyblPRL1PT.asIrTyhbNALVqVyReTG3NVrC5nBeXz.", remote_ip: {127, 0, 0, 1}, req_cookies: %Plug.Conn.Unfetched{aspect: :cookies}, req_headers: [{"accept", "application/vnd.api+json"}, {"content-type", "application/vnd.api+json"}], request_path: "/api/sessions/reply", resp_body: nil, resp_cookies: %{}, resp_headers: [{"content-type", "application/vnd.api+json; charset=utf-8"}, {"cache-control", "max-age=0, private, must-revalidate"}, {"x-request-id", "v4d2kglood7q4lg089v2orrktievu1jp"}], scheme: :http, script_name: [], secret_key_base: "95bLxwzq6dwjySDiMxa/z7hWCzzCdMlnJROgZYZpNc5D13WmQKWQ3MdoQkQThtPg", state: :unset, status: 401}, 401, %{})
(plug) lib/plug/conn.ex:429: Plug.Conn.send_resp/3
(how_we_doin) web/controllers/session_controller.ex:1: HowWeDoin.SessionController.action/2
(how_we_doin) web/controllers/session_controller.ex:1: HowWeDoin.SessionController.phoenix_controller_pipeline/2
(how_we_doin) lib/phoenix/router.ex:261: HowWeDoin.Router.dispatch/2
(how_we_doin) web/router.ex:1: HowWeDoin.Router.do_call/2
(how_we_doin) lib/how_we_doin/endpoint.ex:1: HowWeDoin.Endpoint.phoenix_pipeline/1
(how_we_doin) lib/phoenix/endpoint/render_errors.ex:34: HowWeDoin.Endpoint.call/2
(phoenix) lib/phoenix/test/conn_test.ex:194: Phoenix.ConnTest.dispatch/5
test/api/weekly_status_reply_test.exs:25
.
Finished in 0.3 seconds (0.1s on load, 0.1s on tests)
3 tests, 2 failures
Randomized with seed 51734
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment