Skip to content

Commit

Permalink
Failing to construct identical lock with certain arguments (test)
Browse files Browse the repository at this point in the history
  • Loading branch information
challengee committed Mar 7, 2013
1 parent d364a7e commit 4fc9ea2
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions test/lock_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,14 @@ def test_lock
assert_equal 1, Resque.redis.llen('queue:lock_test')
end

def test_lock_arguments
client_arguments = :test
client_lock = Job.lock(client_arguments)
job_arguments = Resque.decode(Resque.encode(client_arguments))
job_lock = Job.lock(job_arguments)
assert_equal client_lock, job_lock
end

def test_deadlock
now = Time.now.to_i

Expand Down

0 comments on commit 4fc9ea2

Please sign in to comment.