mirror of
https://github.com/mperham/sidekiq.git
synced 2022-11-09 13:52:34 -05:00
21 lines
319 B
Ruby
21 lines
319 B
Ruby
# frozen_string_literal: true
|
|
require_relative 'helper'
|
|
|
|
class TestUtil < Sidekiq::Test
|
|
|
|
class Helpers
|
|
include Sidekiq::Util
|
|
end
|
|
|
|
def test_tid
|
|
x = Sidekiq::Util.tid
|
|
y = nil
|
|
t = Thread.new do
|
|
Sidekiq::Util.tid
|
|
end
|
|
y = t.value
|
|
assert x
|
|
assert y
|
|
refute_equal x, y
|
|
end
|
|
end
|