Exception: RSpec::GraphqlIntegration::Matchers::MatchGraphqlResponse::TestVariableMissing
- Inherits:
-
ArgumentError
- Object
- ArgumentError
- RSpec::GraphqlIntegration::Matchers::MatchGraphqlResponse::TestVariableMissing
- Defined in:
- lib/rspec/graphql_integration/matchers/match_graphql_response.rb
Overview
This error is thrown when a variable is missing that is required for the GraphQL response matcher.
Instance Method Summary collapse
-
#initialize(variable_name, example_value) ⇒ TestVariableMissing
constructor
A new instance of TestVariableMissing.
Constructor Details
#initialize(variable_name, example_value) ⇒ TestVariableMissing
Returns a new instance of TestVariableMissing.
13 14 15 16 17 18 19 20 |
# File 'lib/rspec/graphql_integration/matchers/match_graphql_response.rb', line 13 def initialize(variable_name, example_value) super <<~TEXT Test variable #{variable_name} is missing. Please define it, e.g. with: let(:#{variable_name}) { #{example_value} } TEXT end |