class Spec::Matchers::Migration::HaveTableMatcher
Attributes
repository[RW]
table_name[RW]
Public Class Methods
new(table_name)
click to toggle source
# File lib/spec/matchers/migration_matchers.rb, line 25 def initialize(table_name) @table_name = table_name end
Public Instance Methods
failure_message()
click to toggle source
# File lib/spec/matchers/migration_matchers.rb, line 33 def failure_message %(expected #{repository} to have table '#{table_name}') end
matches?(repository)
click to toggle source
# File lib/spec/matchers/migration_matchers.rb, line 29 def matches?(repository) repository.adapter.storage_exists?(table_name) end
negative_failure_message()
click to toggle source
# File lib/spec/matchers/migration_matchers.rb, line 37 def negative_failure_message %(expected #{repository} to not have table '#{table_name}') end