Sha256: f2768f0cd22880d5be4afaa433059b44c20cb0ea617c68aec8995e1dc6455cf2
Contents?: true
Size: 342 Bytes
Versions: 5
Compression:
Stored size: 342 Bytes
Contents
module ActiveMocker class Table attr_reader :name, :fields def initialize(name, fields=[]) @name = name @fields = fields fields.unshift Field.new('id', :integer, {}) end def to_h {name: name, fields: fields.to_h} end def column_names fields.map { |f| f.name } end end end
Version data entries
5 entries across 5 versions & 1 rubygems