mirror of
https://github.com/plausible/analytics.git
synced 2024-12-02 07:38:47 +03:00
Revert async where env is relied upon
This commit is contained in:
parent
4768ca2edd
commit
b7098f6da6
@ -1,5 +1,5 @@
|
||||
defmodule PlausibleWeb.Api.ExternalSitesControllerTest do
|
||||
use PlausibleWeb.ConnCase, async: true
|
||||
use PlausibleWeb.ConnCase, async: false
|
||||
use Plausible.Repo
|
||||
|
||||
setup %{conn: conn} do
|
||||
@ -62,7 +62,7 @@ defmodule PlausibleWeb.Api.ExternalSitesControllerTest do
|
||||
end
|
||||
|
||||
test "does not allow creating more sites than the limit", %{conn: conn, user: user} do
|
||||
Application.put_env(:plausible, :site_limit, 3)
|
||||
patch_env(:site_limit, 3)
|
||||
insert(:site, members: [user])
|
||||
insert(:site, members: [user])
|
||||
insert(:site, members: [user])
|
||||
|
@ -7,10 +7,7 @@ defmodule PlausibleWeb.FirewallTest do
|
||||
@blocked_ip "127.0.0.2"
|
||||
@opts [blocklist: [@blocked_ip]]
|
||||
|
||||
setup do
|
||||
Application.put_env(:plausible, PlausibleWeb.Firewall, blocklist: [@blocked_ip])
|
||||
:ok
|
||||
end
|
||||
setup_patch_env(PlausibleWeb.Firewall, blocklist: [@blocked_ip])
|
||||
|
||||
test "ignores request if IP is allowed" do
|
||||
conn =
|
||||
|
Loading…
Reference in New Issue
Block a user