FrontendStaticPlugTest: Fix test
This commit is contained in:
parent
60800c0b2b
commit
b9f135eaf3
@ -4,7 +4,11 @@
|
|||||||
|
|
||||||
defmodule Pleroma.Web.Plugs.FrontendStaticPlugTest do
|
defmodule Pleroma.Web.Plugs.FrontendStaticPlugTest do
|
||||||
use Pleroma.Web.ConnCase
|
use Pleroma.Web.ConnCase
|
||||||
|
|
||||||
import Mock
|
import Mock
|
||||||
|
import Mox
|
||||||
|
|
||||||
|
alias Pleroma.UnstubbedConfigMock, as: ConfigMock
|
||||||
|
|
||||||
@dir "test/tmp/instance_static"
|
@dir "test/tmp/instance_static"
|
||||||
|
|
||||||
@ -66,6 +70,9 @@ defmodule Pleroma.Web.Plugs.FrontendStaticPlugTest do
|
|||||||
File.mkdir_p!("#{path}/proxy/rr/ss")
|
File.mkdir_p!("#{path}/proxy/rr/ss")
|
||||||
File.write!("#{path}/proxy/rr/ss/Ek7w8WPVcAApOvN.jpg:large", "FB image")
|
File.write!("#{path}/proxy/rr/ss/Ek7w8WPVcAApOvN.jpg:large", "FB image")
|
||||||
|
|
||||||
|
ConfigMock
|
||||||
|
|> stub_with(Pleroma.Test.StaticConfig)
|
||||||
|
|
||||||
url =
|
url =
|
||||||
Pleroma.Web.MediaProxy.encode_url("https://pbs.twimg.com/media/Ek7w8WPVcAApOvN.jpg:large")
|
Pleroma.Web.MediaProxy.encode_url("https://pbs.twimg.com/media/Ek7w8WPVcAApOvN.jpg:large")
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user