Shared reading of a test module's AST for the setup-key checks: what a
setup returns, and which of those keys each test consumes.
A test consumes a key by destructuring it, by reading it off its context
binding (ctx.key), or by handing that context to a helper defined in the
same file that does either. Calls this module cannot resolve — remote or
imported — make the test opaque, and an opaque test consumes every key in
scope, since the alternative is a false positive on the whole fixture.
Summary
Functions
The bodies of every describe block in ast.
Every def/defp in ast, keyed by name and arity.
The context keys a pattern destructures, ignoring underscored bindings.
The body of the first defmodule in ast.
The keys the first setup in body returns, and the line it sits on.
The context keys the setup in body destructures from its own argument.
Every test in body, as %{name:, keys:, line:, opaque?:}.
Functions
The bodies of every describe block in ast.
Every def/defp in ast, keyed by name and arity.
Clauses of the same function are collected together, since the context may reach any of them.
The context keys a pattern destructures, ignoring underscored bindings.
The body of the first defmodule in ast.
The keys the first setup in body returns, and the line it sits on.
The context keys the setup in body destructures from its own argument.
Every test in body, as %{name:, keys:, line:, opaque?:}.
keys are the context keys the test consumes; opaque? marks a test that
hands its context to something unresolvable, whose key use cannot be known.