Sha256: eb46051449a6afe4865567254d9e9f0e9bb9f3bb50e2a1432f423fc885f92366
Contents?: true
Size: 596 Bytes
Versions: 9
Compression:
Stored size: 596 Bytes
Contents
module RSpec::RubyContentMatchers def have_remove_column(name) HaveCall.new('t.remove', ":#{name}") end def have_add_column(name, type='string') HaveCall.new("t.#{type}", ":#{name}") end alias_method :have_column, :have_add_column def have_columns(columns = {}) raise ArgumentError, "Columns must be passed as a :name => :type Hash" if !columns.kind_of? Hash HaveCalls.new columns end def have_change_column(name, type='string') HaveCall.new("t.change", ":#{name}\s*,\s*:#{type}") end def have_timestamps HaveCall.new("t.timestamps") end end
Version data entries
9 entries across 9 versions & 1 rubygems