Preload: Load the correct instance panel
[akkoma] / test / web / preload / instance_test.exs
index 52f9bab3b4546c13af8d07b80645b4df851bb42a..df150d7bebc1163aed7bfb7f890d5dd82ae97d76 100644 (file)
@@ -15,7 +15,7 @@ defmodule Pleroma.Web.Preload.Providers.InstanceTest do
              registrations: true
            } = info
 
-    assert String.equivalent?(description, "A Pleroma instance, an alternative fediverse server")
+    assert String.equivalent?(description, "Pleroma: An efficient and flexible fediverse server")
   end
 
   test "it renders the panel", %{"/instance/panel.html": panel} do
@@ -25,6 +25,17 @@ defmodule Pleroma.Web.Preload.Providers.InstanceTest do
            )
   end
 
+  test "it works with overrides" do
+    clear_config([:instance, :static_dir], "test/fixtures/preload_static")
+
+    %{"/instance/panel.html": panel} = Instance.generate_terms(nil)
+
+    assert String.contains?(
+             panel,
+             "HEY!"
+           )
+  end
+
   test "it renders the node_info", %{"/nodeinfo/2.0": nodeinfo} do
     %{
       metadata: metadata,