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 errors import_error.ex
Raw

lib/errors/import_error.ex

defmodule WormwoodImportError do
@moduledoc """
An exception raised by Wormwood when it cannot find a file imported via an
`#import "some_file.gql"` statement
"""
defexception [:path, :parent]
def message(exception) do
"Wormwood failed to load imported file '#{exception.path}' imported in file '#{
exception.parent
}'"
end
end