class Shoulda::Matchers::Graphql::Types::HaveDescription
Attributes
type_description[RW]
Public Class Methods
new(type_description)
click to toggle source
# File lib/shoulda/matchers/graphql/types/have_description.rb, line 12 def initialize(type_description) @type_description = type_description end
Public Instance Methods
description()
click to toggle source
# File lib/shoulda/matchers/graphql/types/have_description.rb, line 21 def description "have description '#@type_description'" end
failure_message()
click to toggle source
# File lib/shoulda/matchers/graphql/types/have_description.rb, line 25 def failure_message "expected #@subject to have description '#@type_description', but it was '#{@subject.description}'" end
matches?(subject)
click to toggle source
Calls superclass method
# File lib/shoulda/matchers/graphql/types/have_description.rb, line 16 def matches?(subject) super(subject) @subject.description == type_description end