lib/daiku/plugins/sidekiq/cli.rb in daiku-0.1.0 vs lib/daiku/plugins/sidekiq/cli.rb in daiku-0.1.1
- old
+ new
@@ -39,14 +39,19 @@
def rackup
content = <<-SKMW.strip_heredoc
require 'sidekiq/web'
map '/sidekiq' do
Sidekiq::Web.use Rack::Auth::Basic do |username, password|
- username == ENV['SIDEKIQ_USERNAME'] && password == ENV['SIDEKIQ_PASSWORD']
+ username == ENV['SIDEKIQ_USERNAME'] && password == ENV['SIDEKIQ_PASSWORD']
+ end
+ run Sidekiq::Web\n
end
- run Sidekiq::Web
SKMW
append_to_file "#{app}/config.ru", content
+ end
+
+ def spechelper
+ insert_into_file "#{app}/spec/spec_helper.rb", "require 'sidekiq/testing'\n", before: "require 'minitest/autorun'\n"
end
end
end
end
end