Sha256: 51c9e189c2f41311eb438bcc2364c55e1a14243af95ca4750291064521cb4ef3
Contents?: true
Size: 1.27 KB
Versions: 13
Compression:
Stored size: 1.27 KB
Contents
require 'test_helper' require 'sidekiq' require 'harness/integration/sidekiq' class SidekiqIntegrationTest < IntegrationTest def middleware Sidekiq::Middleware::Server::HarnessInstrumentation.new end def tests_logs_job_performance_stats middleware.call("report", nil, nil) { } assert_gauge_logged "report.sidekiq" assert_counter_logged "reports.sidekiq" end def tests_logs_a_counter_of_all_jobs middleware.call("reports", nil, nil) { } assert_counter_logged "job.sidekiq" end def test_ignores_harness_jobs middleware.call("Harness::SidekiqQueue::SendCounter", nil, nil) { } assert_empty counters assert_empty gauges middleware.call("Harness::SidekiqQueue::SendGauge", nil, nil) { } assert_empty counters assert_empty gauges middleware.call(Harness::SidekiqQueue::SendCounter, nil, nil) { } assert_empty counters assert_empty gauges middleware.call(Harness::SidekiqQueue::SendGauge, nil, nil) { } assert_empty counters assert_empty gauges middleware.call(Harness::SidekiqQueue::SendCounter.new, nil, nil) { } assert_empty counters assert_empty gauges middleware.call(Harness::SidekiqQueue::SendGauge.new, nil, nil) { } assert_empty counters assert_empty gauges end end
Version data entries
13 entries across 13 versions & 1 rubygems