File tree Expand file tree Collapse file tree 3 files changed +25
-3
lines changed
Expand file tree Collapse file tree 3 files changed +25
-3
lines changed Original file line number Diff line number Diff line change 4040 - SECRET_KEY_BASE
4141 - STRIPE_SECRET_KEY
4242 - STRIPE_SIGNING_SECRET
43+ - STRIPE_PUBLIC_KEY
44+ - STRIPE_PRICE_DEV_MONTHLY
45+ - STRIPE_PRICE_TEAM_MONTHLY
4346 - SMTP_PASSWORD
4447 - ACTIVERABBIT_DATABASE_PASSWORD
4548 - PGHOST
6164 # Sidekiq configuration
6265 SIDEKIQ_CONCURRENCY : 10
6366
64- # Public keys (non-sensitive)
65- STRIPE_PUBLIC_KEY : pk_live_your_stripe_public_key
67+ # Email configuration
6668 MAILER_FROM_EMAIL : noreply@your-domain.com
6769 ALERT_FROM_EMAIL : alerts@your-domain.com
6870 SMTP_HOST : smtp.your-provider.com
Original file line number Diff line number Diff line change 1616# }
1717# }) if defined?(Sidekiq::Cron)
1818
19- if defined? ( Sidekiq ::Cron ) && ENV [ "REDIS_URL" ] . present? && !ActiveModel ::Type ::Boolean . new . cast ( ENV [ "DISABLE_SIDEKIQ_CRON" ] )
19+ if defined? ( Sidekiq ::Cron ) && ENV [ "REDIS_URL" ] . present? && !ActiveModel ::Type ::Boolean . new . cast ( ENV [ "DISABLE_SIDEKIQ_CRON" ] ) && ! Rails . env . test?
2020 jobs = {
2121 "report_usage_daily" => {
2222 "cron" => "0 1 * * *" ,
Original file line number Diff line number Diff line change 4545 post '/api/v1/events/performance' , params : body , headers : headers
4646 expect ( response ) . to have_http_status ( :unprocessable_entity )
4747 end
48+
49+ it 'accepts controller/action details from metadata' do
50+ body = {
51+ name : 'controller.action' ,
52+ duration_ms : 87.5 ,
53+ metadata : {
54+ controller : 'HomeController' ,
55+ action : 'index' ,
56+ method : 'GET' ,
57+ path : '/home' ,
58+ db_runtime : 12.3 ,
59+ view_runtime : 4.2
60+ }
61+ } . to_json
62+
63+ post '/api/v1/events/performance' , params : body , headers : headers
64+ expect ( response ) . to have_http_status ( :created )
65+ json = JSON . parse ( response . body )
66+ expect ( json [ 'status' ] ) . to eq ( 'created' )
67+ end
4868 end
4969
5070 describe 'POST /api/v1/events/batch' do
You can’t perform that action at this time.
0 commit comments