spec/locker_spec.rb in restruct-0.2.0 vs spec/locker_spec.rb in restruct-1.0.0
- old
+ new
@@ -83,10 +83,10 @@
test_id = Restruct.generate_id[:test]
locker_id = locker.id
pids = 10.times.map do |thread_number|
Process.fork do
- connection = Restruct::Connection.new
+ connection = Restruct::Connection.simple
locker = Restruct::Locker.new id: locker_id, connection: connection
10.times do |iteration|
locker.lock :process_1 do
connection.call 'RPUSH', test_id, "#{thread_number}-#{iteration}"
end
\ No newline at end of file