I have a Ecto schema, that uses a arc uploader as a field type.
schema "files" do
field :name, :string
field :locked, :boolean, default: false
field :mime_type, :string
field :path, Splish.Assets.FilesUploader.Type
field :size, :integer
belongs_to :user, Splish.Accounts.User
timestamps()
end
I would like to add a exmachina factory for this
def file_factory do
%File{
name: "Gyldendal",
locked: false,
mime_type: "png",
size: 200,
# path: "test/support/image.png",
user: insert(:user)
}
end
How would i go about that?
From Arc Basic Usage
I would do: