1 defmodule Pleroma.LoadTesting.Helper do
2 alias Ecto.Adapters.SQL
5 def to_sec(microseconds), do: microseconds / 1_000_000
8 IO.puts("Deleting old data...\n")
9 SQL.query!(Repo, "TRUNCATE users CASCADE;")
10 SQL.query!(Repo, "TRUNCATE activities CASCADE;")
11 SQL.query!(Repo, "TRUNCATE objects CASCADE;")
12 SQL.query!(Repo, "TRUNCATE oban_jobs CASCADE;")