Class: GraphQL::Autotest::Report::Execution

Inherits:
Struct
  • Object
show all
Defined in:
lib/graphql/autotest/report.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#queryObject

Returns the value of attribute query

Returns:

  • (Object)

    the current value of query



4
5
6
# File 'lib/graphql/autotest/report.rb', line 4

def query
  @query
end

#resultObject

Returns the value of attribute result

Returns:

  • (Object)

    the current value of result



4
5
6
# File 'lib/graphql/autotest/report.rb', line 4

def result
  @result
end

Instance Method Details

#query_summaryObject



5
6
7
# File 'lib/graphql/autotest/report.rb', line 5

def query_summary
  query.lines[1].strip
end

#to_error_messageObject



9
10
11
# File 'lib/graphql/autotest/report.rb', line 9

def to_error_message
  query_summary + "\n" + result['errors'].inspect
end