diff options
author | Egor Kislitsyn <egor@kislitsyn.com> | 2020-06-29 16:09:49 +0400 |
---|---|---|
committer | Egor Kislitsyn <egor@kislitsyn.com> | 2020-06-29 16:09:49 +0400 |
commit | 4a306720e8be8633e192f7b2c98f129a315939b9 (patch) | |
tree | ed5ec059c532777a28eade72f384c8a800ead496 /test/http_test.exs | |
parent | d15aa9d9503e59b3cd0731394855781f435ec63c (diff) | |
parent | 651f269568cb7e54cd96d8a0d8ea3533f77e9a3a (diff) | |
download | pleroma-4a306720e8be8633e192f7b2c98f129a315939b9.tar.gz pleroma-4a306720e8be8633e192f7b2c98f129a315939b9.zip |
Merge branch 'develop' into remove-twitter-api
Diffstat (limited to 'test/http_test.exs')
-rw-r--r-- | test/http_test.exs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/http_test.exs b/test/http_test.exs index 618485b55..d394bb942 100644 --- a/test/http_test.exs +++ b/test/http_test.exs @@ -17,6 +17,9 @@ defmodule Pleroma.HTTPTest do } -> json(%{"my" => "data"}) + %{method: :head, url: "http://example.com/hello"} -> + %Tesla.Env{status: 200, body: ""} + %{method: :get, url: "http://example.com/hello"} -> %Tesla.Env{status: 200, body: "hello"} @@ -27,6 +30,12 @@ defmodule Pleroma.HTTPTest do :ok end + describe "head/1" do + test "returns successfully result" do + assert HTTP.head("http://example.com/hello") == {:ok, %Tesla.Env{status: 200, body: ""}} + end + end + describe "get/1" do test "returns successfully result" do assert HTTP.get("http://example.com/hello") == { |