rspec-goodies 0.1.1 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b84bb1a1e7947039692f5fe8aa0aafa794ca92d0a926ecfd48b508a909b0fb14
4
- data.tar.gz: c937c9f6aa8b86fbefaa7be56b778bd1892cf08c0b5185ecba3e68833d62b90c
3
+ metadata.gz: 329814af431141f0f8bbcf536e7fb7a44c93443d72a04a5de828846221142ad3
4
+ data.tar.gz: 9593b164a64de413f98ef93b974c030b0516fd5f304d04338cef0bd4e6c3b75c
5
5
  SHA512:
6
- metadata.gz: 2522ba744dede8da8c355c80f08b0bb42982103ea9258c159b4a5efac350aabc4844697e9788f84c93eb6fb7e1374a5b42573cf836b998ce6d7caec2f9f1ec21
7
- data.tar.gz: 96166c7f3e661350217f917fa00d7d30eeb7f8f83298ad97fb01110c33495f3e26ff39e5a70c544e7229c6c15ce182b10f11d0e88c2d1b75a8f8efba45559cb3
6
+ metadata.gz: 4f8aa401ba3286dd94104b5eb5338b165b4a7a834a47e9f31b3a5a04fcb8bbce568fe30fa7bd6492fc411ce856d4458fd138a33bcb5fb33aec427f9dd273deb6
7
+ data.tar.gz: 3bf310ebe13ad2c26dddad8ee924ea680874dcc2645a141f2d15c162ed1d734c90a27ebf99194737587267580c2206b79e285426b99da114cc0bf4738b19e6c0
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- rspec-goodies (0.1.1)
4
+ rspec-goodies (0.1.3)
5
5
  activesupport
6
6
  byebug
7
7
  rails
@@ -46,7 +46,7 @@ module RSpec
46
46
  def process_sidekiq_payloads(payloads)
47
47
  payloads.each do |payload|
48
48
  payload_hash = ::Sidekiq.load_json(payload)
49
- worker_class = ::Sidekiq::Testing.constantize(payload_hash["class"])
49
+ worker_class = Object.const_get(payload_hash["class"])
50
50
 
51
51
  worker_class.process_job(payload_hash)
52
52
  end
@@ -44,13 +44,14 @@ class SidekiqJobsEnqueuedMatcher
44
44
 
45
45
  expect(Array(job[key])).to match(value)
46
46
  when "at"
47
- if (scheduled_at = job[key])
47
+ # If nil, then we are looking for jobs that aren't scheduled
48
+ if value.nil?
49
+ expect(job.key?("at")).to eq false
50
+ else
48
51
  # It's a float in job
49
- expect(scheduled_at).to eq(value.to_f)
52
+ scheduled_at = job[key]
50
53
 
51
- # Otherwise if nil, then we are looking for jobs that aren't scheduled
52
- else
53
- expect(job.key?("at")).to eq false
54
+ expect(scheduled_at).to eq(value.to_f)
54
55
  end
55
56
  when "bid"
56
57
  expect(job[key]).to match(value)
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "rspec-goodies"
5
- spec.version = "0.1.1"
5
+ spec.version = "0.1.3"
6
6
  spec.authors = ["James Hu"]
7
7
 
8
8
  spec.summary = "RSpec goodies full of helpers, matchers, and more"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rspec-goodies
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Hu
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-08-03 00:00:00.000000000 Z
11
+ date: 2024-10-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport