Pleroma.Web.AdminAPI.Config -> Pleroma.ConfigDB
This commit is contained in:
Alexander Strizhakov 2020-01-16 08:50:27 +03:00
commit 29155137fd
No known key found for this signature in database
GPG key ID: 022896A53AEF1381
10 changed files with 173 additions and 171 deletions

View file

@ -5,7 +5,7 @@
defmodule Pleroma.Config.TransferTaskTest do
use Pleroma.DataCase
alias Pleroma.Web.AdminAPI.Config
alias Pleroma.ConfigDB
clear_config(:configurable_from_database) do
Pleroma.Config.put(:configurable_from_database, true)
@ -16,19 +16,19 @@ defmodule Pleroma.Config.TransferTaskTest do
refute Application.get_env(:idna, :test_key)
refute Application.get_env(:quack, :test_key)
Config.create(%{
ConfigDB.create(%{
group: ":pleroma",
key: ":test_key",
value: [live: 2, com: 3]
})
Config.create(%{
ConfigDB.create(%{
group: ":idna",
key: ":test_key",
value: [live: 15, com: 35]
})
Config.create(%{
ConfigDB.create(%{
group: ":quack",
key: ":test_key",
value: [:test_value1, :test_value2]
@ -48,7 +48,7 @@ defmodule Pleroma.Config.TransferTaskTest do
end
test "non existing atom" do
Config.create(%{
ConfigDB.create(%{
group: ":pleroma",
key: ":undefined_atom_key",
value: [live: 2, com: 3]