updated ScheduledActivity
[akkoma] / test / support / helpers.ex
index ce39dd9d8fad52ccaa405d36a10388068e3a8a45..ec556a916cb96302002fcfca8a234072c2026c4a 100644 (file)
@@ -53,6 +53,12 @@ defmodule Pleroma.Tests.Helpers do
           clear_config_all: 2
         ]
 
+      def to_datetime(naive_datetime) do
+        naive_datetime
+        |> DateTime.from_naive!("Etc/UTC")
+        |> DateTime.truncate(:second)
+      end
+
       def collect_ids(collection) do
         collection
         |> Enum.map(& &1.id)