summaryrefslogtreecommitdiff
path: root/test/support/helpers.ex
diff options
context:
space:
mode:
authorrinpatch <rinpatch@sdf.org>2020-02-11 00:04:06 +0000
committerrinpatch <rinpatch@sdf.org>2020-02-11 00:04:06 +0000
commit94e5ca11054567e0edc15ef3a350f02c386d3ead (patch)
tree36f42f1532c76e44d3959e368a046bff474aea3b /test/support/helpers.ex
parenta7287e2e3a9291469c489a5a1df26480fdeab3a3 (diff)
parent6813c0302c2b665d337d5f5831d2df6312b6b277 (diff)
downloadpleroma-94e5ca11054567e0edc15ef3a350f02c386d3ead.tar.gz
pleroma-94e5ca11054567e0edc15ef3a350f02c386d3ead.zip
Merge branch 'issue/1383' into 'develop'
[#1383] Switch periodic jobs from quantum to oban See merge request pleroma/pleroma!2015
Diffstat (limited to 'test/support/helpers.ex')
-rw-r--r--test/support/helpers.ex6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/support/helpers.ex b/test/support/helpers.ex
index 9f817622d..d36c29cef 100644
--- a/test/support/helpers.ex
+++ b/test/support/helpers.ex
@@ -54,6 +54,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)