Sha256: 7df10c4c03ec2349ebf93d12f3a9ac0e3be89a65996d613a01106cdfe1fbdaa4

Contents?: true

Size: 1.08 KB

Versions: 66

Compression:

Stored size: 1.08 KB

Contents

Given /^I have setup database cleaner to clean multiple databases using activerecord$/ do
  #DatabaseCleaner
  # require "#{File.dirname(__FILE__)}/../../../lib/datamapper_models"
  #
  # DatabaseCleaner[:datamapper, {:connection => :one} ].strategy = :truncation
  # DatabaseCleaner[:datamapper, {:connection => :two} ].strategy = :truncation
end

When /^I create a widget using activerecord$/ do
  ActiveRecordWidget.create!
end

Then /^I should see ([\d]+) widget using activerecord$/ do |widget_count|
  ActiveRecordWidget.count.should == widget_count.to_i
end

When /^I create a widget in one db using activerecord$/ do
  ActiveRecordWidgetUsingDatabaseOne.create!
end

When /^I create a widget in another db using activerecord$/ do
  ActiveRecordWidgetUsingDatabaseTwo.create!
end

Then /^I should see ([\d]+) widget in one db using activerecord$/ do |widget_count|
  ActiveRecordWidgetUsingDatabaseOne.count.should == widget_count.to_i
end

Then /^I should see ([\d]+) widget in another db using activerecord$/ do |widget_count|
  ActiveRecordWidgetUsingDatabaseTwo.count.should == widget_count.to_i
end

Version data entries

66 entries across 55 versions & 8 rubygems

Version Path
database_cleaner-1.6.2 examples/features/step_definitions/activerecord_steps.rb
database_cleaner-1.6.1 examples/features/step_definitions/activerecord_steps.rb
database_cleaner-1.6.0 examples/features/step_definitions/activerecord_steps.rb
autocompl-0.2.2 test/dummy/vendor/bundle/ruby/2.3.0/gems/database_cleaner-1.5.3/examples/features/step_definitions/activerecord_steps.rb
autocompl-0.2.1 test/dummy/vendor/bundle/ruby/2.3.0/gems/database_cleaner-1.5.3/examples/features/step_definitions/activerecord_steps.rb
autocompl-0.2.0 test/dummy/vendor/bundle/ruby/2.3.0/gems/database_cleaner-1.5.3/examples/features/step_definitions/activerecord_steps.rb
autocompl-0.1.2 test/dummy/vendor/bundle/ruby/2.3.0/gems/database_cleaner-1.5.3/examples/features/step_definitions/activerecord_steps.rb
autocompl-0.1.1 test/dummy/vendor/bundle/ruby/2.3.0/gems/database_cleaner-1.5.3/examples/features/step_definitions/activerecord_steps.rb
autocompl-0.1.0 test/dummy/vendor/bundle/ruby/2.3.0/gems/database_cleaner-1.5.3/examples/features/step_definitions/activerecord_steps.rb
autocompl-0.0.1 test/dummy/vendor/bundle/ruby/2.3.0/gems/database_cleaner-1.5.3/examples/features/step_definitions/activerecord_steps.rb
database_cleaner-1.5.3 examples/features/step_definitions/activerecord_steps.rb
database_cleaner-1.5.2 examples/features/step_definitions/activerecord_steps.rb
database_cleaner-1.5.1 examples/features/step_definitions/activerecord_steps.rb
database_cleaner-1.5.0 examples/features/step_definitions/activerecord_steps.rb
solidus_backend-1.0.0.pre3 vendor/bundle/gems/database_cleaner-1.4.1/examples/features/step_definitions/activerecord_steps.rb
solidus_backend-1.0.0.pre2 vendor/bundle/gems/database_cleaner-1.4.1/examples/features/step_definitions/activerecord_steps.rb
solidus_backend-1.0.0.pre vendor/bundle/gems/database_cleaner-1.4.1/examples/features/step_definitions/activerecord_steps.rb
database_cleaner-1.4.1 examples/features/step_definitions/activerecord_steps.rb
database_cleaner-1.4.0 examples/features/step_definitions/activerecord_steps.rb
apl-library-0.0.90 vendor/bundle/ruby/2.1.0/gems/database_cleaner-1.2.0/examples/features/step_definitions/activerecord_steps.rb