Skip to content

Phoenix.Router.NoRouteError message should not be changed #375

@quexpl

Description

@quexpl

Environment

  • Elixir version (elixir -v): Elixir 1.9.1
  • Erlang/OTP version (erl): Erlang/OTP 22 [erts-10.4.4]
  • Sentry version (mix deps): 7.2.0
  • Operating system: Ubuntu 16.04.6 LTS

Description

When using Sentry.Phoenix.Endpoint error message of the Phoenix.Router.NoRouteError exception is changed to default (no route found).

After adding sentry to our project, one of test is failing:

  test "responses with not found if team not exists", %{conn: conn} do
    assert_raise Phoenix.Router.NoRouteError,
                 ~r/no route found for GET \/non-existing-company\/machines/,
                 fn ->
                   get(conn, "/non-existing-company/machines")
                 end
  end
  1) test responses with not found if team not exists (WebappWeb.TeamPrefixTest)
     test/webapp_web/plugs/team_prefix_test.exs:59
     Wrong message for Phoenix.Router.NoRouteError
     expected:
       ~r/no route found for GET \/non-existing-company\/machines/
     actual:
       "no route found"
     code: assert_raise Phoenix.Router.NoRouteError,
     stacktrace:
       test/webapp_web/plugs/team_prefix_test.exs:60: (test)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions