Skip to content

Commit

Permalink
Run the formatter
Browse files Browse the repository at this point in the history
  • Loading branch information
tomtaylor committed Jul 24, 2023
1 parent 20e0496 commit 9d6ab2b
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions test/mox_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,13 @@ defmodule Snap.MoxTest do

setup_all do
:ok = GenServer.stop(Cluster)
{:ok, _} = Cluster.start_link(
url: "http://localhost:9200",
http_client_adapter: HTTPClientMock,
skip_initialize_http_client: true
)

{:ok, _} =
Cluster.start_link(
url: "http://localhost:9200",
http_client_adapter: HTTPClientMock,
skip_initialize_http_client: true
)

on_exit(fn ->
url = "http://localhost:9200"
Expand All @@ -22,10 +24,10 @@ defmodule Snap.MoxTest do
end)
end


test "mox" do
Mox.expect(HTTPClientMock, :request, fn _cluster, _method, _url, _headers, _body, _opts ->
body = "{}" # valid json
# valid json
body = "{}"
{:ok, %Snap.HTTPClient.Response{status: 200, headers: [], body: body}}
end)

Expand Down

0 comments on commit 9d6ab2b

Please sign in to comment.