Sha256: c753cd773d86d83ca7277aba4fab7e28ca9788c41030b05093d1cd3c2f1ba1bb

Contents?: true

Size: 688 Bytes

Versions: 1

Compression:

Stored size: 688 Bytes

Contents

require 'coveralls'
Coveralls.wear! do
  add_filter "/test/"
end

Encoding.default_external = Encoding::UTF_8
Encoding.default_internal = Encoding::UTF_8

require "minitest/autorun"
require "minitest/pride"
require "mocha/setup"

require "sidekiq"
require "sidekiq-lock"
require "test_workers"

Sidekiq.logger.level = Logger::ERROR

REDIS = Sidekiq::RedisConnection.create(url: "redis://localhost/15", namespace: "sidekiq_lock_test")

def redis(command, *args)
  Sidekiq.redis do |c|
    c.send(command, *args)
  end
end

def set_lock_variable!(value = nil)
  Thread.current[Sidekiq::Lock::THREAD_KEY] = value
end

def lock_thread_variable
  Thread.current[Sidekiq::Lock::THREAD_KEY]
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
sidekiq-lock-0.3.0 test/test_helper.rb