Packages

Wormwood is a tiny library to aid in testing GraphQL queries against an Absinthe schema. It allows you to test your query documents inside ExUnit test modules, and requires no HTTP requests to occur during testing.

Current section

Files

Jump to
wormwood lib examples types.ex
Raw

lib/examples/types.ex

defmodule Wormwood.Examples.Types do
@moduledoc false
use Absinthe.Schema.Notation
object :user do
field :id, :id
field :name, :string
field :email, :string
field :messages, list_of(:message)
end
object :message do
field :id, :id
field :from, :user
field :message, :string
end
end