2010-05-16 16:44:09 -04:00
2010-04-13 11:50:25 -04:00
Given / ^I am using (ActiveRecord|DataMapper|MongoMapper|Mongoid|CouchPotato)$ / do | orm |
2010-05-16 16:44:09 -04:00
@feature_runner = FeatureRunner . new
@feature_runner . orm = orm
end
2010-06-15 10:24:50 -04:00
Given / ^I am using (ActiveRecord|DataMapper|MongoMapper|CouchPotato|Mongoid) and (ActiveRecord|DataMapper|MongoMapper|CouchPotato|Mongoid)$ / do | orm1 , orm2 |
2010-05-16 16:44:09 -04:00
@feature_runner = FeatureRunner . new
@feature_runner . orm = orm1
@feature_runner . another_orm = orm2
2009-03-03 23:53:21 -05:00
end
Given / ^the (.+) cleaning strategy$ / do | strategy |
2010-05-16 16:44:09 -04:00
@feature_runner . strategy = strategy
2009-03-03 23:53:21 -05:00
end
When " I run my scenarios that rely on a clean database " do
2010-05-16 16:44:09 -04:00
@feature_runner . go 'example'
2009-03-03 23:53:21 -05:00
end
2010-05-16 16:55:43 -04:00
When " I run my scenarios that rely on clean databases " do
2010-05-25 13:21:45 -04:00
@feature_runner . multiple_databases = true
2010-05-16 16:55:43 -04:00
@feature_runner . go 'example_multiple_db'
2009-03-03 23:53:21 -05:00
end
2010-05-16 16:44:09 -04:00
When " I run my scenarios that rely on clean databases using multiple orms " do
2010-05-16 16:56:26 -04:00
@feature_runner . go 'example_multiple_orm'
2010-05-16 16:44:09 -04:00
end
2009-03-03 23:53:21 -05:00
2010-05-16 16:44:09 -04:00
Then " I should see all green " do
fail " Feature failed with : #{ @feature_runner . output } " unless @feature_runner . exit_status == 0
2010-05-30 23:12:58 -04:00
end