Sha256: 2d19cca63b9a5e478b192cdff8d38c96e5ed582ab307578dfe75693fc29bac5e
Contents?: true
Size: 456 Bytes
Versions: 4
Compression:
Stored size: 456 Bytes
Contents
#!/usr/bin/env ruby # # A one file test to show ... require 'rubygems' gem('dm-core', '~> 0.9.8') require 'dm-core' # setup the logger DataMapper::Logger.new(STDOUT, :debug) # connect to the DB DataMapper.setup(:default, 'sqlite3::memory:') class <%= model_name %> include DataMapper::Resource # properties property :id, Serial <% properties.each do |name, type| -%> property :<%= name %>, <%= type %> <% end %> end DataMapper.auto_migrate!
Version data entries
4 entries across 4 versions & 1 rubygems