Sha256: c63147be09aadfb4d83592f174abfe4a1caeafb5039cb642df6d1efb0ea75a3f
Contents?: true
Size: 764 Bytes
Versions: 2
Compression:
Stored size: 764 Bytes
Contents
require File.dirname(__FILE__) + '/../test_helper' class AbsenceTest < Test::Unit::TestCase main_scenario def teardown Thread.current[:user] = nil end def test_legal_to_mark_date_as_absent_if_there_is_registered_work_on_same_date Thread.current[:user] = users(:tesla) Absence.create!({:on => '2007-06-12', :user_id => 1000001, :reason => 'lazy'}) end def test_create_with_anonymous_not_allowed assert_raise ActiveRecord::RecordInvalid do Absence.create!({:on => '2007-06-12', :user_id => nil, :reason => 'lazy'}) end end private # TODO (uwe): This method should be removed # It is here only because ClassTableInheritanceInRails broke reading fixtures by name def users(login) super(login) end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
backlog-0.35.4 | test/unit/absence_test.rb |
backlog-0.35.5 | test/unit/absence_test.rb |