Sha256: 87a2d2c6f78d108c0d8f09fdfc5c76612793882e50780bf4a535af24a0559590

Contents?: true

Size: 575 Bytes

Versions: 29

Compression:

Stored size: 575 Bytes

Contents

require File.dirname(__FILE__) + '/../test_helper'

class RcrmActsAsVotableTest < ActiveSupport::TestCase

  class NotVotable < ActiveRecord::Base; end
  def test_that_votable_returns_false_unless_included
    assert_equal NotVotable.votable?, false
  end

  def test_that_votable_returns_true_if_included
    assert_equal Votable.votable?, true
  end

  def test_behaves_like_votable_model
    assert Voter.create(:name => 'i can vote!')
    assert VotableCache.create(:name => 'voting model with cache')
    assert VotableVoter.create(:name => 'i can vote too!')
  end
end

Version data entries

29 entries across 29 versions & 3 rubygems

Version Path
redmine_crm-0.0.63 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.62 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.61 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.60 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.59 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.58 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.57 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.56 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.55 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.54 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.53 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.52 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.51 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.50 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.49 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.48 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.47 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.46 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.45 test/acts_as_votable/rcrm_acts_as_votable_test.rb
redmine_crm-0.0.44 test/acts_as_votable/rcrm_acts_as_votable_test.rb