comfycamp/test/support/fixtures/sso_fixtures.ex

23 lines
492 B
Elixir

defmodule Comfycamp.SSOFixtures do
@moduledoc """
This module defines test helpers for creating
entities via the `Comfycamp.SSO` context.
"""
@doc """
Generate a oidc_app.
"""
def oidc_app_fixture(attrs \\ %{}) do
{:ok, oidc_app} =
attrs
|> Enum.into(%{
client_id: "some client_id",
client_secret: "some client_secret",
enabled: true,
name: "some name"
})
|> Comfycamp.SSO.create_oidc_app()
oidc_app
end
end