Remove call to Pleroma.Web.Endpoint.config_change/2

This is not necessary for the tests to pass and breaks other tests as this change doesn't get cleanly reverted causing the hostname to stay set this way and leak into other test causing failures with "sub.example.com" not matching "localhost"
This commit is contained in:
Mark Felder 2023-11-28 21:00:58 +00:00
parent 36b3867787
commit d4dd21303a
1 changed files with 1 additions and 13 deletions

View File

@ -55,12 +55,7 @@ test "Webfinger JRD" do
]
end
test "reach user on tld, while pleroma is running on subdomain" do
Pleroma.Web.Endpoint.config_change(
[{Pleroma.Web.Endpoint, url: [host: "sub.example.com"]}],
[]
)
test "reach user on tld, while pleroma is runned on subdomain" do
clear_config([Pleroma.Web.Endpoint, :url, :host], "sub.example.com")
clear_config([Pleroma.Web.WebFinger, :domain], "example.com")
@ -75,13 +70,6 @@ test "reach user on tld, while pleroma is running on subdomain" do
assert response["subject"] == "acct:#{user.nickname}@example.com"
assert response["aliases"] == ["https://sub.example.com/users/#{user.nickname}"]
on_exit(fn ->
Pleroma.Web.Endpoint.config_change(
[{Pleroma.Web.Endpoint, url: [host: "localhost"]}],
[]
)
end)
end
test "it returns 404 when user isn't found (JSON)" do