diff options
author | Haelwenn <contact+git.pleroma.social@hacktivis.me> | 2022-09-05 15:38:15 +0000 |
---|---|---|
committer | Haelwenn <contact+git.pleroma.social@hacktivis.me> | 2022-09-05 15:38:15 +0000 |
commit | 346c130ddca08a6927e9290a164212bf88463ca5 (patch) | |
tree | c5a3618fbd4937542a36e7129b8b55b530c8466a /test/support | |
parent | f7c20731034f7aa3c72a6dcc312850db27787f7e (diff) | |
parent | cfb1bc967f857569d8d0088a40e1d16e5cbbeca2 (diff) | |
download | pleroma-346c130ddca08a6927e9290a164212bf88463ca5.tar.gz |
Merge branch 'fix/user-private-key-generation' into 'develop'
User: generate private keys on user creation
See merge request pleroma/pleroma!3737
Diffstat (limited to 'test/support')
-rw-r--r-- | test/support/factory.ex | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/test/support/factory.ex b/test/support/factory.ex index b01aff3ab..c54d65b62 100644 --- a/test/support/factory.ex +++ b/test/support/factory.ex @@ -7,6 +7,7 @@ defmodule Pleroma.Factory do require Pleroma.Constants + alias Pleroma.Keys alias Pleroma.Object alias Pleroma.User @@ -28,6 +29,8 @@ defmodule Pleroma.Factory do end def user_factory(attrs \\ %{}) do + {:ok, pem} = Keys.generate_rsa_pem() + user = %User{ name: sequence(:name, &"Test ใในใ User #{&1}"), email: sequence(:email, &"user#{&1}@example.com"), @@ -39,7 +42,8 @@ defmodule Pleroma.Factory do last_refreshed_at: NaiveDateTime.utc_now(), notification_settings: %Pleroma.User.NotificationSetting{}, multi_factor_authentication_settings: %Pleroma.MFA.Settings{}, - ap_enabled: true + ap_enabled: true, + keys: pem } urls = |