forked from ruby-shoryuken/shoryuken
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Rakefile
43 lines (34 loc) · 972 Bytes
/
Rakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
require 'bundler/gem_tasks'
$stdout.sync = true
begin
require 'rspec/core/rake_task'
RSpec::Core::RakeTask.new(:spec) do |t|
t.exclude_pattern = 'spec/integration/**/*_spec.rb'
end
namespace :spec do
desc 'Run Rails specs only'
RSpec::Core::RakeTask.new(:rails) do |t|
t.pattern = 'spec/shoryuken/{environment_loader_spec,extensions/active_job_*}.rb'
end
desc 'Run integration specs only'
RSpec::Core::RakeTask.new(:integration) do |t|
t.pattern = 'spec/integration/**/*_spec.rb'
end
end
rescue LoadError
end
desc 'Open Shoryuken pry console'
task :console do
require 'pry'
require 'shoryuken'
config_file = File.join File.expand_path(__dir__), 'shoryuken.yml'
if File.exist? config_file
config = YAML.load File.read(config_file)
Aws.config = config['aws']
end
def push(queue, message)
Shoryuken::Client.queues(queue).send_message(message_body: message)
end
ARGV.clear
Pry.start
end