Sysmo DB

Mailer unit test occasionally fails because of timestamp differences

Details

  • Type: Bug Bug
  • Status: Resolved Resolved
  • Priority: Minor Minor
  • Resolution: Fixed
  • Affects Version/s: None
  • Fix Version/s: 0.5.0
  • Component/s: None
  • Labels:
    None

Description

test_signup(MailerTest) - line 15

test fails because the actual value is computed 1 second after the expected value is computed and so assert_equal fails. Only happens occasionally (presumably when CPU usage is high whilst running tests)

Activity

Hide
Finn Bacall added a comment - 2009-10-08 14:20

time_test_helper.rb added with method pretend_now_is(time, &block) to override Time.now calls to return 'time' within the given block.

Show
Finn Bacall added a comment - 2009-10-08 14:20 time_test_helper.rb added with method pretend_now_is(time, &block) to override Time.now calls to return 'time' within the given block.

People

Vote (0)
Watch (0)

Dates

  • Created:
    2009-10-05 14:02
    Updated:
    2009-10-08 14:20
    Resolved:
    2009-10-08 14:20

Time Tracking

Estimated:
30m
Original Estimate - 30 minutes
Remaining:
30m
Remaining Estimate - 30 minutes
Logged:
Not Specified
Time Spent - Not Specified