sidekiq-batch 0.1.1 → 0.1.2

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
  SHA1:
3
- metadata.gz: eb4ca160ca9606d8656d6af7892721e70cfc5611
4
- data.tar.gz: b48fe8be7ca9d62a2c825b0251e608a2763b9a8a
3
+ metadata.gz: 1fe037d539fb1492eb690004dfd48a03727beadf
4
+ data.tar.gz: 3bad40562aa7abd37fc677ae4bf65c6393053d4b
5
5
  SHA512:
6
- metadata.gz: 63a0a5ead721e2bcd4b8e69e3e22fa68fb124a5eef9068bd4a71df5bf647a1a8c75a27250b46d487dac06722d11bedf4119dc2fba70b654b3edc51e2540778cd
7
- data.tar.gz: c073415bbe4420dc460fef344ec9f48f9fa970bc436ae62109bc75fb9992c195639769c4d4b4b409b97663c8b94f5a7833358149cc24f393cabfa8c27dedcd76
6
+ metadata.gz: d12d34ce2b8d9ee4d823f1c32406403322a402ab5fc4104c46b6b1cfffca94d12732ff50c09c238666fd333787b3e546eac412529a8c840860bc182ad57014a8
7
+ data.tar.gz: bdbc01d26ef53401a420fc78baf0e715ff3d609a950b0987c318d17a5ac9ce67c6e97fb9005fff79a31e2f1e33eb16b9c26ffbb9fb09e6f645a9e3c4977aa8a6
data/.travis.yml CHANGED
@@ -3,3 +3,5 @@ language: ruby
3
3
  rvm:
4
4
  - 2.3.1
5
5
  before_install: gem install bundler -v 1.12.5
6
+ after_success:
7
+ - bundle exec codeclimate-test-reporter
data/Gemfile CHANGED
@@ -3,5 +3,6 @@ source 'https://rubygems.org'
3
3
  gemspec
4
4
 
5
5
  group :test do
6
- gem 'codeclimate-test-reporter'
6
+ gem "simplecov"
7
+ gem "codeclimate-test-reporter", "~> 1.0.0"
7
8
  end
@@ -6,9 +6,9 @@ module Sidekiq
6
6
 
7
7
  def perform(clazz, event, opts, bid)
8
8
  return unless %w(success complete).include?(event)
9
- instance = clazz.constantize.send(:new) rescue nil
10
- return unless instance
11
- instance.send("on_#{event}", Sidekiq::Batch::Status.new(bid), opts) rescue nil
9
+ clazz, method = clazz.split("#") if (clazz.class == String && clazz.include?("#"))
10
+ method = "on_#{event}" if method.nil?
11
+ clazz.constantize.new.send(method, Sidekiq::Batch::Status.new(bid), opts) rescue nil
12
12
  end
13
13
  end
14
14
 
@@ -1,5 +1,5 @@
1
1
  module Sidekiq
2
2
  class Batch
3
- VERSION = '0.1.1'.freeze
3
+ VERSION = '0.1.2'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sidekiq-batch
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Marcin Naglik
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-09-13 00:00:00.000000000 Z
11
+ date: 2016-12-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sidekiq