Hi All,
I am having trouble understanding how migrate_up! works, and I suspect
I'm missing something very simple. I have what may be the simplest
migration file... I cut it down to the point where all it does is log:
--------------------------------------------------------------------
require 'dm-migrations/migration_runner'
DataMapper::Logger.new(STDOUT, :debug)
DataMapper.logger.debug( "Starting Migration" )
migration 1, :allow_multiple_tabs do
up do
DataMapper.logger.debug( "Migration 1 UP" )
end
down do
DataMapper.logger.debug( "Migration 1 DOWN" )
end
end
migrate_up!
DataMapper.logger.debug( "Finished Migration" )
--------------------------------------------------------------------
In irb I run this:
require 'rubygems'
require 'data_mapper'
require 'lib/migrations' (the file above)
And, all I get is this - no sign that it tried to bring up the
migration:
~ Starting Migration
~ Finished Migration
=> true
This is where I'd assume that, like activerecord, the migration
framework has some belief that the migration already ran and is
skipping it, but dm-migrations don't seem to store state anywhere I
can find (or have found documented).
Any ideas?
Thanks,
Tom
--
You received this message because you are subscribed to the Google Groups
"DataMapper" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/datamapper?hl=en.