class ActiveRecordTest::IntegrationTest

Public Instance Methods

test_should_be_available() click to toggle source
# File test/unit/integrations/active_record_test.rb, line 76
def test_should_be_available
  assert StateMachine::Integrations::ActiveRecord.available?
end
test_should_have_a_locale_path() click to toggle source
# File test/unit/integrations/active_record_test.rb, line 92
def test_should_have_a_locale_path
  assert_not_nil StateMachine::Integrations::ActiveRecord.locale_path
end
test_should_have_an_integration_name() click to toggle source
# File test/unit/integrations/active_record_test.rb, line 72
def test_should_have_an_integration_name
  assert_equal :active_record, StateMachine::Integrations::ActiveRecord.integration_name
end
test_should_have_defaults() click to toggle source
# File test/unit/integrations/active_record_test.rb, line 88
def test_should_have_defaults
  assert_equal e = {:action => :save}, StateMachine::Integrations::ActiveRecord.defaults
end
test_should_match_if_class_inherits_from_active_record() click to toggle source
# File test/unit/integrations/active_record_test.rb, line 80
def test_should_match_if_class_inherits_from_active_record
  assert StateMachine::Integrations::ActiveRecord.matches?(new_model)
end
test_should_not_match_if_class_does_not_inherit_from_active_record() click to toggle source
# File test/unit/integrations/active_record_test.rb, line 84
def test_should_not_match_if_class_does_not_inherit_from_active_record
  assert !StateMachine::Integrations::ActiveRecord.matches?(Class.new)
end